AUR package listed as dependancy?

So I just wanted to update the system and hence updating the python2-wxpython3 AUR package failed I took a look at it (what is it, do I need it?) and it says “Install Reason: Installed as a dependency for another package”.

Now first of all: I didn’t know AUR packages can be dependencies. In the Info thread in this board however I read that deprecated Manjaro packages can get moved to AUR, maybe this is the case here? Then I’d like to find out which packages requires this but I don’t know how to interpret the ouput of pactree python2-wxpython3 and this also results in “package not found”. Can anyone give me a hint?

They can … but more likely it or another package was demoted to the AUR.

You probably want

pactree -r python2-wxpython3

Which will show you everything that depends on that package.

If you mean pacman -Si … well it only works for repo packages.
pacman -Qi on the other hand should work for any installed package. ex:

pacman -Qi python2-wxpython3
3 Likes

Hi @xser,

AFAIK python2 is EOL, or something like it. Thus it has been removeed from the repositories and moved to the AUR. You should be able to remove it safely is there is no dependencies for it. You can check that by running:

pamac info python2-wxpython3 | grep --ignore-case '^Required'

If it returns an empty string, you should be able to safely remove it:

pamac remove python2-wxpython3

Hope this helps!

2 Likes

Is EOL since January 1, 2020: Sunsetting Python 2 | Python.org

1 Like

Thanks guys, both pacman and pactree report that it is currently not required by any packages.

I wonder though how it ended up remaining left behind after the package that installed it as depedency was removed

Depends how you did the removal.
pacman -Rns for example would also remove packages no longer needed by any other package, bu -R would not. Similarly if a package was replaced, its possible your package manager then simply replaced the package requiring it, with no extra removal triggered.
We call packages like this ‘orphans’.
You can print out a list of them like this:

pacman -Qdt

https://wiki.archlinux.org/title/Pacman/Tips_and_tricks#Removing_unused_packages_(orphans)

1 Like

I suppose keeping a separate unlinked python2 under /opt would suffice in the case of foreign (non-mainstream) packages; should any still require it.