fix(publish): store PyPI token per user
Some checks failed
Mark stable commit / test-unit (push) Has been cancelled
Mark stable commit / test-integration (push) Has been cancelled
Mark stable commit / test-env-virtual (push) Has been cancelled
Mark stable commit / test-env-nix (push) Has been cancelled
Mark stable commit / test-e2e (push) Has been cancelled
Mark stable commit / test-virgin-user (push) Has been cancelled
Mark stable commit / test-virgin-root (push) Has been cancelled
Mark stable commit / linter-shell (push) Has been cancelled
Mark stable commit / linter-python (push) Has been cancelled
Mark stable commit / mark-stable (push) Has been cancelled
Some checks failed
Mark stable commit / test-unit (push) Has been cancelled
Mark stable commit / test-integration (push) Has been cancelled
Mark stable commit / test-env-virtual (push) Has been cancelled
Mark stable commit / test-env-nix (push) Has been cancelled
Mark stable commit / test-e2e (push) Has been cancelled
Mark stable commit / test-virgin-user (push) Has been cancelled
Mark stable commit / test-virgin-root (push) Has been cancelled
Mark stable commit / linter-shell (push) Has been cancelled
Mark stable commit / linter-python (push) Has been cancelled
Mark stable commit / mark-stable (push) Has been cancelled
https://chatgpt.com/share/693f2e20-b94c-800f-9d8e-0c88187f7be6
This commit is contained in:
@@ -84,10 +84,13 @@ def publish(
|
|||||||
raise RuntimeError("No build artifacts found in dist/.")
|
raise RuntimeError("No build artifacts found in dist/.")
|
||||||
|
|
||||||
resolver = TokenResolver()
|
resolver = TokenResolver()
|
||||||
|
|
||||||
|
# Store PyPI token per OS user (keyring is already user-scoped).
|
||||||
|
# Do NOT scope by project name.
|
||||||
token = resolver.get_token(
|
token = resolver.get_token(
|
||||||
provider_kind="pypi",
|
provider_kind="pypi",
|
||||||
host=target.host,
|
host=target.host,
|
||||||
owner=target.project,
|
owner=None,
|
||||||
options=ResolutionOptions(
|
options=ResolutionOptions(
|
||||||
interactive=interactive,
|
interactive=interactive,
|
||||||
allow_prompt=allow_prompt,
|
allow_prompt=allow_prompt,
|
||||||
|
|||||||
Reference in New Issue
Block a user