Skip to content

Distributing: First time registration fails when following guide. #309

@bernhardreiter

Description

@bernhardreiter

As a first time user of pypi uploading I've following the current official guide
which right now is https://github.com/pypa/python-packaging-user-guide/blob/e548d9febaddb94dce34a5b860110e825cd71493/source/distributing.rst#id122 .

Using the advise of the first note and going to testpypi, I've used the instructions at https://wiki.python.org/moin/TestPyPI to set up an .pypirc with the repository = settings.
Of course I've used this for the real pypi as well and then the implicit registration with twine failed.

My next step was to try if twine had a register command, but I could not easily find out how it works because twine version 1.8.1 (pkginfo: 1.4.1, requests: 2.13.0, setuptools: 35.0.2,
requests-toolbelt: 0.7.1, clint: 0.5.1) --help does not tell me and does not hint that twine register --help would give help to me. My solution was to lookup the source code for twine and find out how it works, which was time-consuming and frustrating.

Now I'm reporting the issue, because I was only a first time user once, now the problem is solved for me, but other first-time users will run into this with a good chance.

So reading up on it:

  • New tutorials: publish a package #204 would be a solution of course, but looks like a lot more work.
  • The discussion in Remove "twine register" reference in distributing.rst #271 shows that you are on to the problem in principle, but the combination of other information sources and the guide still lead to the difficulty remaining unsolved so far. And the difference in the repository = attribute is to little to be recognised. Potential course of action: Add another warning that it is important to leave out the ``repository = ``` attribute to the real .pypirc for implicit registration to work.
  • Update the wiki at https://wiki.python.org/moin/TestPyPI , which is good, but because there may be other places of outdated information, it is not enough.
  • Improve twine to give a better error message like: You are using the old api to pypi, try using the new one by leaving out the repository = attribute.

Metadata

Metadata

Assignees

No one assigned

    Labels

    type: bugA confirmed bug or unintended behavior

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions