by kalebealves » Fri Jun 21, 2024 1:26 pm
The problem with this package is that it installs a version of cockpit that installs cockpit-bridge python modules to /usr/lib/python3.11 while the python version used by archlinux arm currently is 3.12. This way, although the login succeeds with a valid password, it returns a "User/password incorrect" since the cockpit-bridge fails to load.
The ideal solution would be to provide an updated version of cockpit that used the correct python version, or build the package packing the right path for the python modules(3.12 as of the current version).
There are many possible fix for this you can run in the meantime...
1. you can edit the cockpit-bridge script by adding `sys.path.append('/usr/lib/python3.11/site-packages/')` before it's being used by this line "from cockpit.bridge import main".
2. you can add the same path to the python load system at the systemd service.
3. you can just copy the cockpit files from "/usr/lib/python3.11".
1st option is not good since future updates to a version that doesn't have the correct code will likely overwrite that(that might not be the case... I'm not sure if pacman checks if the file has been modified. I know that it does for config files. also, there might be other scripts that use the same path and you might end up with other broken stuff inside cockpit.
2nd option is not bad, but you will have to remember always to check if the problem has been fixed after updates in order to remove the quick fix from the systemd service.
3rd option to me is the best one. while not Ideal, it will at least make pacman scream at you when they fix the problem, and pacman tries to write the files to the folder(3.12). This way you will just have to overwrite the files by the pacman argument. If it is not clear, it is better to me because it will force you to intervene and if overwriting, there will likely not be any letter over in future updates.
In the meantime, I hope they update this package soon, cause It has been broken for almost a month and I just got the time to investigate now.
I suggest changing the post title to something like "cockpit package broken - wrong python modules path".