RedBearAK / toshy

Keymapper config to make Linux work like a 'Tosh!
https://toshy.app
GNU General Public License v3.0
379 stars 19 forks source link

(Question) Dependency conflicts in repo on Ubuntu 22.04 LTS (title edited) #433

Open SawkeeReemo opened 3 weeks ago

SawkeeReemo commented 3 weeks ago

I'm following along in the setup guide right now, and even though I don't know why I might need it, I have installed the AppIndicator and KStatusNotifierItem extension. But there seems to be some sort of bug with it where it is duplicating all of my tray icons. I'm not sure why we need this extension to run toshy, but I turned it off. Anyone know how to fix this or why it is needed to run toshy? It wasn't clear to me from the ReadMe. [Ubuntu LTS 22.04]

RedBearAK commented 3 weeks ago

@SawkeeReemo

It sounds like you already have some sort of extension installed that provides support for legacy tray icons. (There are several that do.) In which case you don’t need the suggested AppIndicator extension. As long as you can see Toshy’s tray icon.

That extension is recommended because it’s the one that is usually working on new GNOME releases, and doesn’t do anything else.

The extension that is essential if you use a Wayland session is any of the three extensions that provide window context info over D-Bus. Only one working extension is necessary, but all can be installed and enabled at the same time without causing an issue.

Any other problems?

RedBearAK commented 3 weeks ago

I'm following along in the setup guide right now, and even though I don't know why I might need it, I have installed the AppIndicator and KStatusNotifierItem extension.

If you can point to where you saw a reference to the AppIndicator extension, maybe I can clarify some of the text to make it easier to understand whether you need that specific extension or not. I know it's referenced in a few places.

SawkeeReemo commented 3 weeks ago

I'm following along in the setup guide right now, and even though I don't know why I might need it, I have installed the AppIndicator and KStatusNotifierItem extension.

If you can point to where you saw a reference to the AppIndicator extension, maybe I can clarify some of the text to make it easier to understand whether you need that specific extension or not. I know it's referenced in a few places.

Sure thing, right here: https://github.com/RedBearAK/toshy?tab=readme-ov-file#managing-shell-extensions-in-gnome

I’m relatively new to Linux, so I don’t always know how to find out if something is installed. I will say that I have never, to my knowledge, installed any extension managers until following your guide here. I wanted to keep Ubuntu pretty vanilla until I knew more about how everything works.

And thanks for offering to help me further, I was a little confused by the requirements section since it shows two different versions of Python for different stage on the install. I’m assuming that those are just minimum requirement for each stage? I have 3.10 installed.

Lastly, I did try to run the installer, but I got an error that wasn’t clear. If you happen to know how to fix this before I start going down a rabbit hole, that’d be cool. Haha:

DD) Home user local bin not part of PATH string.

(!!) NOTICE: It is ESSENTIAL to have your system completely updated.

Have you updated your system recently? [y/N]: y

The "~/.local/bin" folder is not in PATH. OK to add it? [Y/n]: y

§  Getting environment information...
================================================================================
The active init system is: 'systemd' (Systemd)

(EE) ENV: XDG_SESSION_TYPE is 'tty' for some reason. Why?
(EE) ERR: DE not found in XDG_SESSION_DESKTOP, XDG_CURRENT_DESKTOP or DESKTOP_SESSION.
(EE) ERR: Config file may not be able to adapt automatically to Desktop Environment.
(EE) Desktop may be misidentified: 'None'
'gnome' was detected and will be used instead.
(EV) Toshy installer sees this environment:
         DISTRO_ID        = 'ubuntu'
         DISTRO_VER       = '22.04'
         VARIANT_ID       = 'notfound'
         SESSION_TYPE     = 'x11'
         DESKTOP_ENV      = 'gnome'
         DE_MAJ_VER       = '42'
         WINDOW_MGR       = 'gnome-shell'

Is user "minilink" an admin user that can run "sudo" commands? [y/n]: y

Using elevated privileges...

§  Installing native packages for this distro type...
================================================================================
Reading package lists... Done
Building dependency tree... Done
Reading state information... Done
python3-dbus is already the newest version (1.2.18-3build1).
python3-dbus set to manually installed.
curl is already the newest version (7.81.0-1ubuntu1.18).
git is already the newest version (1:2.34.1-1ubuntu1.11).
libnotify-bin is already the newest version (0.7.9-3ubuntu5.22.04.1).
libnotify-bin set to manually installed.
zenity is already the newest version (3.42.1-0ubuntu1).
zenity set to manually installed.
Some packages could not be installed. This may mean that you have
requested an impossible situation or if you are using the unstable
distribution that some required packages have not yet been created
or been moved out of Incoming.
The following information may help to resolve the situation:

The following packages have unmet dependencies:
 libsystemd-dev : Depends: libsystemd0 (= 249.11-0ubuntu3.7) but 249.11-0ubuntu3.12 is to be installed
 python3-dev : Depends: python3 (= 3.10.6-1~22.04) but 3.10.6-1~22.04.1 is to be installed
 python3-venv : Depends: python3 (= 3.10.6-1~22.04) but 3.10.6-1~22.04.1 is to be installed
E: Unable to correct problems, you have held broken packages.

(EE) ERROR: Problem installing package list for distro type:
        Command '['sudo', 'apt', 'install', '-y', 'curl', 'git', 'gir1.2-ayatanaappindicator3-0.1', 'input-utils', 'libcairo2-dev', 'libdbus-1-dev', 'libgirepository1.0-dev', 'libjpeg-dev', 'libnotify-bin', 'libsystemd-dev', 'libwayland-dev', 'libxkbcommon-dev', 'python3-dbus', 'python3-dev', 'python3-pip', 'python3-tk', 'python3-venv', 'zenity']' returned non-zero exit status 100.
RedBearAK commented 3 weeks ago

I wanted to keep Ubuntu pretty vanilla until I knew more about how everything works.

And that's usually a good idea. Unfortunately, there's no other way to get the window class/title info in Wayland sessions, besides using one of the third-party shell extensions that I found. And pretty much everyone enables some sort of extension to get tray icons back. Although Ubuntu usually already has one enabled.

a little confused by the requirements section since it shows two different versions of Python for different stage on the install. I’m assuming that those are just minimum requirement

Yes, that's just indicating that you can run the installer script with an older version of Python than the keymapper needs. This is only of interest on a super ancient distro like CentOS 7 (which is basically dead now).

I did try to run the installer, but I got an error that wasn’t clear.

Sorry, you've got yourself a pretty serious problem there, and I don't know how to fix it. I started seeing that issue on Zorin 16, and Ubuntu Kylin 22.04, but then it also started happening on regular Ubuntu 22.04 LTS, where earlier states of Ubuntu 22.04 LTS were working just fine. Originally Zorin 16 also worked, but when I tested a fresh install of it recently it had that same problem, and it was impossible to install Toshy successfully.

What's happening there is a fundamental package version incompatibility in the Ubuntu 22.04 repos. As you can see in the dependencies, some of the packages like libsystemd-dev want an exact package version (using "=" instead of ">=" for matching) for some other package, but that is not what will be installed from the repo. This is a major screw-up on the part of the Ubuntu repo maintainers. I don't know why it hasn't been fixed by now. It's been happening for months.

I've tried to look into the problem before, but I don't know of any workaround other than telling you to upgrade your system to 24.04 LTS (if you need an LTS version).

I've never run into anything like this on any other distro type, or on any other version of Ubuntu besides those distros I mentioned that were based on Ubuntu 22.04 LTS.

Sorry for the bad news.

SawkeeReemo commented 3 weeks ago

No worries at all, not your fault. I’m reluctant to upgrade to 24.04 until they have more of the bugs worked out. But I haven’t done too much other than altering my fstab and written a bunch of scripts to automate certain tasks, all which should be easily portable. Most things are running in Docker containers as well, so easy to migrate.

I might install 24.04 on a different hard drive and see if I can get everything up and running again.

Thanks for the info and your work on this. I hope they fix 22.04 though. That seems like a huge problem.

EDIT: Is there anywhere I can report this?

RedBearAK commented 3 weeks ago

Is there anywhere I can report this?

I don't know. I'm sure there's some place to contact package or repo maintainers for Ubuntu, but in cases like this I always think that if anyone cared to fix it, it would have already been fixed quite a while ago. I'd just try googling "contact ubuntu package maintainers" or something.

I mostly use Fedora and didn't have the time to mess with making reports on top of supporting all the other distro types that don't have such issues.

Maybe you can prompt someone to finally fix it though.

RedBearAK commented 3 weeks ago

I did a bit of clarification in the README regarding whether the AppIndicator extension is actually needed. Hope it helps someone avoid some confusion.