Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

HTTPError: 403 Client Error: The user '' isn't allowed to upload to project 'iotedgedev'. #4607

Closed
jongio opened this issue Aug 23, 2018 · 12 comments

Comments

@jongio
Copy link

jongio commented Aug 23, 2018

Describe the bug
Trying to upload via twine. New project. Not registered, but getting this:

HTTPError: 403 Client Error: The user '' isn't allowed to upload to project 'iotedgedev'. See https://test.pypi.org/help/#project-name for more information. for url: https://test.pypi.org/legacy/
This is a 404: https://test.pypi.org/project/iotedgedev/

My code works if I change the package name...but would like to not do that.

Expected behavior
Uploads the package

To Reproduce

Try to upload to that project.

My Platform
using git bash

Additional context

@ewdurbin
Copy link
Member

Hello @jongio this project name has already been registered on test.pypi.org and pypi.org.

The users have uploaded releases to PyPI at https://pypi.org/p/iotedgedev, but do not appear to have created any releases on Test PyPI.

As the project name is taken and appears to be an active project it seems selecting another name is your best path forward.

@jongio
Copy link
Author

jongio commented Aug 23, 2018

@ewdurbin There is something fishy going on because the project should be registered to my account. I would like to research who created the project because it is likely me or someone on my team. Can you help me track this down? I am the one who released to pypi proper.

@ewdurbin
Copy link
Member

Test PyPI and PyPI are completely isolated from one another. Can you confirm that you want to be uploading to TestPyPI?

Taking a closer look, it sure does appear that you're one of the owners on the real PyPI!

@jongio
Copy link
Author

jongio commented Aug 23, 2018

Yes, I want to upload the same name to both test and prod pypi, otherwise I would need lots of name replacements through my code and scripts.

Can you add me to that test project or let me know who created it?

Thanks a lot.

@ewdurbin
Copy link
Member

@jongio the existing project with no releases has been removed. you can now register it using your TestPyPI user

@jongio
Copy link
Author

jongio commented Aug 23, 2018

@ewdurbin - I retried and get this error:

HTTPError: 400 Client Error: This filename has already been used, use a different version. See https://test.pypi.org/help/#file-name-reuse for url: https://test.pypi.org/legacy/

@jongio
Copy link
Author

jongio commented Aug 23, 2018

I repushed with a different version in the file name and it worked! Not sure why the other name would have a conflict if there were no releases.

I'm now uploading! Thanks a lot for your help. REALLY appreciate it.

@sank96
Copy link

sank96 commented Jul 23, 2019

Hi I have the same error of "jongio".

HTTPError: 403 Client Error: The user 'Sankios' isn't allowed to upload to project 'simple_logger'. See https://pypi.org/help/#project-name for more information. for url: https://upload.pypi.org/legacy/

This error occurred when I try to upload the new package to pypi.org.

I checked that a package simple_logger already exists, but I named my package simple-logger.

Is the name changed during the upload?

This is a part of my setup.py file

setuptools.setup(
    name="simple-logger",
    version="0.0.1",

@jamadden
Copy link
Contributor

I checked that a package simple_logger already exists, but I named my package simple-logger.
Is the name changed during the upload?

Yes. PEP 503 defines the PyPI API and states that all project names are normalized:

The name should be lowercased with all runs of the characters ., -, or _ replaced with a single - character.

Thus, the names simple-logger and simple_logger are equivalent.

@sank96
Copy link

sank96 commented Jul 24, 2019

@jamadden thanks for the explanation

@AnhQuoc533
Copy link

Hi @jamadden, I have a similar problem to while trying to upload my package to PyPi (not TestPyPi):

ERROR    HTTPError: 403 Forbidden from https://upload.pypi.org/legacy/
         The user '...' isn't allowed to upload to project 'neural_network'. See https://pypi.org/help/#project-name for more information.

I did check and didn't see any uploaded package with the name neural_network or neural-network. Can you help me check this error, please?
My package name is neural-network and the project name is neural_network.
Thank you.

@di
Copy link
Member

di commented Feb 27, 2023

Please see https://pypi.org/help/#project-name, which explains why this is happening and what you can do about it.

@pypi pypi locked as resolved and limited conversation to collaborators Feb 27, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

6 participants