5

I have made changes to package I had submitted long time back in 2015 now today I added support markdown on pypi and updated setup.py to support pip version 10,

however now I am facing a strange problem: If I run this command

python setup.py sdist upload -r http://pypi.org


Password:  # I enter the password
Submitting dist/maildiff-1.2.1.tar.gz to http://pypi.org
Server response (200): OK

but on pypi its not updated. The strange part is even if I enter wrong password I get the message

Submitting dist/maildiff-1.2.1.tar.gz to http://pypi.org
Server response (200): OK
Ciasto piekarz
  • 7,853
  • 18
  • 101
  • 197
  • I strongly recommend you use `twine` to handle your PyPI management needs, and that you use `test.pypi.org` first to test your process. See https://packaging.python.org/tutorials/packaging-projects/#uploading-the-distribution-archives – Martijn Pieters May 20 '18 at 15:10
  • Also did you use `setup.py register` *first*? – Martijn Pieters May 20 '18 at 15:11
  • well of course , how did I got my package up here https://pypi.org/project/maildiff/#history at first place, I am able to login to pypi – Ciasto piekarz May 20 '18 at 15:13
  • 1
    @MartijnPieters I am able to submit using twine to testPyPi, https://test.pypi.org/project/maildiff/#history but if try `twine upload --repository-url https://pypi.org/ dist/*` I get this: Uploading maildiff-1.2.1.tar.gz 100%|██████████████████████████████████████| 16.3k/16.3k [00:01<00:00, 11.5kB/s] `HTTPError: 405 Client Error: Method Not Allowed for url: https://pypi.org/` – Ciasto piekarz May 20 '18 at 15:32
  • the url for test.pypi has a path you forgot to include. Better still, just use the default repository url (don’t use the switch) – Martijn Pieters May 20 '18 at 15:38
  • used without switch, progress but now I am getting this: ubmitting dist/maildiff-1.2.1.tar.gz to https://upload.pypi.org/legacy/ Upload failed (403): Invalid or non-existent authentication information. error: Upload failed (403): Invalid or non-existent authentication information. I have tried entering password 10-15 times with new updated password but no success – Ciasto piekarz May 20 '18 at 15:50
  • And your login does work directly on the pypi.org website, in your browser? Use https://pypi.org/account/login/ to see if you still have access there. – Martijn Pieters May 20 '18 at 17:24

2 Answers2

11

@Martjin Pieters knew I will get my answer myself, I think I have spoken to him quite a lot of time on SO, so as I was troubleshooting I finally managed to upload to pypi:

I am not sure which one approach worked

twine upload --repository-url https://upload.pypi.org/legacy/ dist/*

or

python setup.py sdist upload

but its finally up yay... Thanks for your inputs @Martjin and your valued time (y)

Ciasto piekarz
  • 7,853
  • 18
  • 101
  • 197
2

Just use the following commands after installing the module twine with Python 3

twine upload  dist/*
username: Enter your https://pypi.org username
Password: Enter your https://pypi.org password

Note: before uploading the package, you must verify your email ID from your pypi account.

Eric Aya
  • 69,473
  • 35
  • 181
  • 253
Abhisek
  • 444
  • 4
  • 9