Score:0

how to remove python package installed by distutils

in flag

When trying to install the TensorFlow Python package on Ubuntu 20.04, the install script failed because it couldn't remove the existing Python package 'wrapt'. Error msg said the reason was it was installed by distutils, and couldn't determine its components to remove.

I tried sudo pip3 uninstall wrapt, and got the same error message.

How can I remove the wrapt package?

us flag
Does it show up when you run `pip3 list`?
in flag
yes, but as stated in my post pip3 can't remove it. Error message is same as that given by TensorFlow installer.
us flag
Can you edit to post the exact error message? Please don't put a screenshot. Rather, post the output as text.
Score:0
in flag

I was able to avoid the problem by installing TensorFlow in a virtualenv, as recommended by the TensorFlow install guide page.

Otherwise, it appears I would have to dive into the distutils documentation on python.org to figure out how to remove a distutils installed package.

denNorske avatar
sl flag
This is not an answer to the question
NotTheDr01ds avatar
vn flag
@denNorske Considering it's a self-answer (OP and answer author are the same), it's tough to say that it wasn't a valid workaround for the OP's *root problem* at least. :-)
NotTheDr01ds avatar
vn flag
Please self-accept your answer so that the question gets closed out, otherwise the question will get bumped (sometimes years) later with no accepted-answer. You can always change the accepted answer later if someone posts a better solution for you.
mangohost

Post an answer

Most people don’t grasp that asking a lot of questions unlocks learning and improves interpersonal bonding. In Alison’s studies, for example, though people could accurately recall how many questions had been asked in their conversations, they didn’t intuit the link between questions and liking. Across four studies, in which participants were engaged in conversations themselves or read transcripts of others’ conversations, people tended not to realize that question asking would influence—or had influenced—the level of amity between the conversationalists.