12

I followed this answer to upgrade the outdated Python packages on my Machine running Ubuntu 18.04.4 LTS. I am using pip 20.0.2.

Now, every time I try to install or upgrade a package, an annoying window pops up asking for the passowrd. For example:

pip install --user -U numpy

I get the following window:

enter image description here

When I press Cancel, I get the following output:

WARNING: Keyring is skipped due to an exception: Failed to unlock the collection!
WARNING: Keyring is skipped due to an exception: Failed to unlock the collection!
Requirement already up-to-date: numpy in /home/user/.local/lib/python3.6/site-packages (1.18.1)

Before this issue, I used to install my packages without sudo privileges and without using the --user flag.

What is wrong with pip? How can I fix that?.

I appreciate your help.

  • 3
    This seems less to do with `pip` and more with ubuntu. see https://askubuntu.com/questions/918712/the-login-keyring-did-not-get-unlocked-when-you-logged-into-your-computer for example – jkr Feb 23 '20 at 19:50
  • 3
    I'm getting this error too, using Fedora. I'm logged in remotely so I can't see the dialog box, if there is one. – nnyby May 19 '20 at 20:54

2 Answers2

1

Go to "User Accounts", set "automatic login" to "off". At startup, you will be asked your user/password only once; I hope it will fix your problem.

Jaied
  • 900
  • 9
  • 13
-2

After years of getting this and similar issues with pip the only solution that has worked every time is to work inside conda.

jb4earth
  • 198
  • 1
  • 6