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

Author output frequently broken for packages using pyproject.toml metadata #9

Open
dgw opened this issue Aug 23, 2024 · 0 comments
Open
Labels
bug Something isn't working

Comments

@dgw
Copy link
Member

dgw commented Aug 23, 2024

This is a specific case of #7 that is so important as to warrant its own issue.

Declaring authorship metadata in a package using pyproject.toml often causes this plugin to output "(unknown author)", due to how the metadata is parsed and exposed by Warehouse (PyPI). For example, this TOML metadata:

authors = [
  { name="dgw", email="dgw@notmyrealemail.tld" }
]

turns into JSON like:

{
  "info": {
    "author": null,
    "author_email": "dgw \u003Cdgw@notmyrealemail.tld\u003E",

The information we want is contained in the author_email field, but since the author's name is null, sopel-pypi treats it as unknown. Unfortunately the information we want is mixed in with information we don't want.

Have been hoping for pypi/warehouse#9400 to get resolved, but it's taking too long. I'd like this plugin to have useful output for packages using the newer metadata standards sooner than the timeline on which PyPI seems inclined to fix this.

@dgw dgw added the bug Something isn't working label Aug 23, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

1 participant