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

ENH: setup.py register --list-classifiers #583

Closed
westurner opened this issue Apr 9, 2020 · 8 comments
Closed

ENH: setup.py register --list-classifiers #583

westurner opened this issue Apr 9, 2020 · 8 comments

Comments

@westurner
Copy link

westurner commented Apr 9, 2020

A command that lists the PyPI trove classifiers just like python setup.py register --list-classifiers (which doesn't work anymore) in order to list the trove classifiers such that they can be grepped.

These are the lists:

Workaround:

curl -s 'https://pypi.org/pypi?%3Aaction=list_classifiers' \
  | grep -Ei 'development status|license'
@jamadden
Copy link
Member

jamadden commented Apr 9, 2020

The canonical source for the classifiers has moved to a project called trove-classifiers. It is calendar-versioned and auto-deployed to PyPI. The full list is at https://github.com/pypa/trove-classifiers/blob/master/trove_classifiers/__init__.py . One could clone that repository and simply grep through it.

@westurner
Copy link
Author

Does twine check check that all of a package's trove classifiers are valid?

Nobody is going to know that they need to install another package to print the list of strs to select from.

See: "ENH: console_script that prints classifiers to stdout" pypa/trove-classifiers#22

@di
Copy link
Sponsor Member

di commented Apr 9, 2020

Does twine check check that all of a package's trove classifiers are valid?

Not yet, but this is planned. See #430 and pypa/packaging#147.

@sigmavirus24
Copy link
Member

@westurner sorting issues by most recently active (GitHub's default) would have shown that and searching github for this information would have saved us all a lot of time.

Closing this as a duplicate of #430

@westurner
Copy link
Author

@sigmavirus24
Printing a list of the classifiers (for use when adding package metadata) is not the same as validating that the classifiers listed are in the curated set.

This was possible with setup.py register --list-classifiers but is not with twine.

I see that this is in flux. Any of these would unbreak the existing functionality (that's been broken for who knows how long now:

  • unbreak setuptools register --list-classifiers
  • add --list-classifiers to twine
  • add a console_script to trove-classifiers

None of these solutions require metadata validation.

@westurner
Copy link
Author

Is this a bug or an enhancement for setuptools, twine, and/or trove-classifiers?

Setuptools is broken (BUG) and it points to twine for register.
Twine doesn't have a register --list-classifiers.
Twine is a different thing then setuptools.
Twine may soon depend upon the (< 3 weeks) new trove-classifiers package, which could instead or also add a script to print the trove classifiers with newlines between them.

@di
Copy link
Sponsor Member

di commented Apr 9, 2020

@westurner Let's consider this a duplicate of pypa/trove-classifiers#22 and continue our discussion there. I see no reason why twine or setuptools should retain this behavior, the register subcommand is long dead.

@sigmavirus24
Copy link
Member

the register subcommand is long dead.

3rd party registries use it, if I remember correctly, so it can never completely die. That said, 99% of our users wouldn't ever want twine register --list-classifiers since they won't ever be using twine register. Better might be twine print-trove-classifiers but that feels like shoving a square peg into a round hole.

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

No branches or pull requests

4 participants