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

twine 6 seems to break twine check "globs" #1187

Closed
1 task done
Julian opened this issue Nov 30, 2024 · 8 comments · Fixed by #1188
Closed
1 task done

twine 6 seems to break twine check "globs" #1187

Julian opened this issue Nov 30, 2024 · 8 comments · Fixed by #1188
Assignees
Labels

Comments

@Julian
Copy link
Contributor

Julian commented Nov 30, 2024

Is there an existing issue for this?

  • I have searched the existing issues (open and closed), and could not find an existing issue

What keywords did you use to search existing issues?

glob
dist*

What operating system are you using?

macOS

If you selected 'Other', describe your Operating System here

What version of Python are you running?

3.12.7

How did you install twine? Did you use your operating system's package manager or pip or something else?

`pip install twine`, but also `uv run` (see below)

What version of twine do you have installed (include the complete output)

twine version 6.0.0 (keyring: 25.5.0, pkginfo: 1.11.2, requests: 2.32.3, requests-toolbelt: 1.0.0, urllib3: 2.2.3)

Which package repository are you using?

pypi production

Please describe the issue that you are experiencing

twine check "dist/*" used to check all distributions in dist.
It's documented as the "way" to use twine check in its --help:

⊙  twine check --help                                                                                                                                                                                                                                                                                                                                             julian@Mac
usage: twine check [-h] [--strict] dist [dist ...]

positional arguments:
  dist        The distribution files to check, usually dist/*

But twine 6 seems to no longer support this. (Here I've cloned the twine repository itself as a test package, and run pyproject-build . on it to produce a dist directory).

⊙  uv run --with 'twine>=6' twine check 'dist/*'                                                                                                                                                                                                                                                                                                                  julian@Mac
Checking dist/*: ERROR    InvalidDistribution: Unknown distribution format: '*' 

Please list the steps required to reproduce this behaviour

Previous versions still work fine of course:

⊙  uv run --with 'twine<6' twine check 'dist/*'                                                                                                                                                                                                                                                                                                                   julian@Mac
Installed 23 packages in 21ms
Checking dist/twine-6.0.1.dev5+g067412e-py3-none-any.whl: PASSED
Checking dist/twine-6.0.1.dev5+g067412e.tar.gz: PASSED

Anything else you'd like to mention?

No response

@Julian Julian added the bug label Nov 30, 2024
@woodruffw
Copy link
Member

Thanks for the report @Julian -- my SWAG is that this is a regression from #1172. I'm looking at it now.

@woodruffw
Copy link
Member

Oh, I think I see what's happening here -- 'dist/*' means that the shell's own globbing isn't used, and the _split_inputs helper isn't handling globs on its own.

@woodruffw
Copy link
Member

#1188 should fix this -- sorry for the breakage @Julian!

@Julian
Copy link
Contributor Author

Julian commented Nov 30, 2024

Hooray! Thanks for the fast fix!

@Julian
Copy link
Contributor Author

Julian commented Dec 1, 2024

Not to press of course, but is the hope to do a 6.0.1 release of twine with this? It essentially breaks CI in all my projects unfortunately (for me), so just checking if I should put any effort into reworking my setups. (Though I guess I will anyhow for pinning twine's own version...)

@woodruffw
Copy link
Member

I can prep a PR for a 6.0.1 release; I need to add a CHANGELOG entry anyways.

@woodruffw
Copy link
Member

I've opened #1189 with the release prep.

@Julian
Copy link
Contributor Author

Julian commented Dec 1, 2024

Amazing, let me know if I can help at all obviously.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants