1

If I run apt list python-py I see the package python-py (which I just installed, via sudo apt install python-py, thinking it was something other than what it is):

Listing... Done
python-py/bionic,bionic 1.5.2-1 all

Attempting to uninstall this package by running sudo apt remove python-py, I am greeted by the following:

Reading package lists... Done
Building dependency tree       
Reading state information... Done
Package 'python-py' is not installed, so not removed
Starting pkgProblemResolver with broken count: 0
Starting 2 pkgProblemResolver with broken count: 0
Done
0 to upgrade, 0 to newly install, 0 to remove and 0 not to upgrade.

apt seems to be contradicting itself, what's going on?

  • 2
    Please edit your question to clearly explain how you installed python-py. If possible, locate the install terminal log in /var/log/apt/term.log, and paste that entire install session (not the whole log). – user535733 Nov 19 '18 at 15:56
0

The apt list command doesn't check just installed packages. It checks the database of all known packages from all known sources, whether installed or not.

Here's an example of apt list of an installed package:

$ apt list python3
Listing... Done
python3/cosmic-updates,now 3.6.7-1~18.10 amd64 [installed]

apt list will clearly tell you which packages are [installed].

| improve this answer | |
0

Welcome to AskUbuntu SE! I think you are mistaken about python-py being installed. apt list will list all the packages available (as said by user535733) Here's a screenshot to assure you :)

enter image description here

| improve this answer | |

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.