PyPi deployment with Travis: Invalid or non-existent authentication

When deploying from Travis CI to PyPi I get the following errors:

HTTPError: 403 Client Error: Invalid or non-existent authentication information. for url:

I’ve have followed closely the Travis CI documentation for pypi deployment and have setup my PyPI username and password, with the it encrypted with the password encryption docs. The password does not have any escape-worthy characters but I’ve tried escaping all characters regardless, but I still get the error.

Nothing seems to work, any advice?

The relevant section of the Travis CI config is:

- provider: pypi
    branch: master
    tags: true
  user: "<<username>>"
    secure: "<<encrypted password>>"
  distributions: "sdist bdist_wheel"
  skip_existing: true

don’t want to reveal secrets on forum but I think the idea here is clear. sorry for all the questions.


After reading this, you should explicitly run travis encrypt against :

travis encrypt <<password>> --com --debug

The debug flag is inherently optional, and provides some added info in the terminal. You can also do

If this doesn’t work try running travis whatsup. Let me know the results, and no need to apologize! This is what we are here for.

1 Like

hey @montana this work when I ran travis-encrypt as suggested