-
Notifications
You must be signed in to change notification settings - Fork 2.3k
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
poetry publish
raises HTTP 403
#6320
Comments
Your credentials should be in |
No, there is no I also checked |
Found that this is the correct format to define API tokens for publish:
Thanks for the help on Discord @neersighted |
https://pypi.org/help/#apitoken for those that stumble across this. |
I just upgraded to poetry 1.2 and am running into this as well. While passing creds on the command line is fine, previous behaviour was that poetry asked for username and password; is that intentionally no longer the case? |
Looks like it managed to escape the changelog through an edge case: Cleo dropped support for the codepath we were using a long time ago, but the code was still in Poetry. It wasn't working due to being missing from Cleo, but wasn't detected due to a lack of tests. A contributor detected it and removed it in #5889 as dead code. A new implementation could be added, but I am more inclined to try and have a helpful error message when no credentials are detected for a publishing target. Was specifying these values interactively (vs. via the environment, keyring, auth config file, or arguments) immensely valuable to you (especially given using a token is best practice)? |
Thanks for the quick response! Makes sense how that escaped changelogging I found specifying them interactively valuable, but "immensely" might be a high bar :-) Passing things interactively avoids secrets going into my command line history or other files. Out of the options you mention, it sounds like keyring would also serve that use case (although I don't see how to set that up / doesn't look like it would work with my password manager).
Note that you could use a token with the old interactive code path, you just needed to set username to |
It's true that you could use a token, but the utility of an interactive flow seems significantly reduced by the need to copy-and-paste. If you just need to keep it from being written to disk unencrypted, why don't you |
Just to let you know, I encountered this issue today. Before As a workaround I created API token and passing it using |
Poetry currently does not support |
This issue has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs. |
-vvv
option).Issue
I can't run
poetry publish
, I tried running it bare-bones; I tried running it with username and password (-u, -p). No luck.Something that stands out from the log:
Not sure where this is stored, but I would love to delete this, and see what happens. I don't know where it is, ideas/knowledge?
/home/can/.config/pypoetry/config.toml
is empty.PyPi link in error log is unapplicable to my problem because I never get to provide my credentials. Error log:
The text was updated successfully, but these errors were encountered: