#127 Unable to register a project via web or command line


I am able to log in to PyPi no problems. However, when I attempt to register my package using the web form, I am prompted again to authenticate, and my credentials aren't accepted and I'm unable to proceed.

When I try "python setup.py register" from the command-line to do the same thing, I am similarly unable to register the package.

The only potentially non-standard thing I can see that I have done is my initial user registration was performed using Oauth rather than username/password. However, I then later explicitly set a password and can log in with a username/password combo.

I'd be happy to just have my user account totally blown away so I can re-register and try again, however if that doesn't fix things then maybe there are bigger problems.


  • I should probably add this note --- my PyPi username is Tennessee.Leeuwenburg

  • Richard Jones
    Richard Jones

    Exactly what happens when you run "python setup.py register"? Have you attempted it from different network locations? What version of Python are you using?

  • tjl@dalek:~/workspace/benchmarker.py$ python setup.py register
    running register
    We need to know who you are, so please choose either:
    1. use your existing login,
    2. register as a new user,
    3. have the server generate a new password for you (and email it to you), or
    4. quit
    Your selection [default 1]:
    Username: Tennessee.Leeuwenburg
    Registering benchmarker.py to http://pypi.python.org/pypi
    Server response (401): basic auth failed

    tjl@dalek:~/workspace/benchmarker.py$ python --version
    Python 2.6.6

    Has been attempted from different network locations and different machines. The code is almost certainly 2.7 or even 3 compatible for that matter if that is relevant. However, I also get an auth error if I try to register through the web page...

  • Richard Jones
    Richard Jones

    Have you confirmed that your password works when you log into the website through a browser, using basic auth and not openid?

  • I'm afraid so... I can log in using the password just fine, but then through the website after using the registration form, I get re-prompted for my credentials, and then it rejects the credentials. :(

  • I mean, I'd never discount the possibility I'm somehow doing something terribly wrong and shortsighted, but I don't think so...

  • It *is* puzzling because it works exactly that way for everybody else. What't the contents of your ~/.pypirc (with the password masked)?

  • Hi Martin... that file doesn't exist on my machine.

    I registered a new user from scratch under a different email address and everything worked fine. So now the package exists on pypi! Sadly I've mucked something up and I can't easy_install it, but it's still awesome to see! (the new username is punctjl). So, my new project is up! benchmarker.py lives! Don't try installing it yet though, I clearly still need to iron some kinks out of the installation process and maybe provide a good tutorial before it's worth looking at.


    • status: open --> closed
  • Computerlyrik

    Same error here.

    Is this a known issue at this time?

    Tried to create 3 logins (2 via webif, 1 via option 3)

    but every time 401 bad auth with "setup.py register"

    tried manual login and setting in ~/.pypirc - both failing.

    Loggin into the webif works. Always.
    Did several Password resets also. What is happening here?

    Last edit: Computerlyrik 2013-09-19
  • Computerlyrik

    Now, on password change the website says:


    There's been a problem with your request

    : new row for relation "accounts_gpgkey" violates check constraint "accounts_gpgkey_valid_key_id" DETAIL: Failing row contains (1254, 46936, , f).