Skip to content

AttributeError caused by author field, breaking poetry build #370

@nackjicholson

Description

@nackjicholson
  • I am on the latest Poetry version.
  • I have searched the issues of this repo and believe that this is not a duplicate.
  • If an exception occurs when executing a command, I executed it again in debug mode (-vvv option).

Issue

poetry build -f sdist

With author field in pyproject.toml

authors = ["R&D <researchanddevelopment@example.com>"]

Output:

[AttributeError]               
'NoneType' object has no attribute 'group'  

Perhaps this is for a good reason, but it confused me for a long while because I didn't know this meant something was wrong in my pyproject.toml file. It would be useful to have indications of toml validation problems by field.

Changed to:

authors = ["Research Development <researchanddevelopment@example.com>"]

Works, and that is fine. Just didn't know there were validation rules for these strings.

Metadata

Metadata

Assignees

No one assigned

    Labels

    kind/bugSomething isn't working as expected

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions