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

Update pyproject.toml so it validates. #2726

Closed
wants to merge 1 commit into from

Conversation

hexmode
Copy link

@hexmode hexmode commented May 20, 2024

While working with the Poetry's proposed support for the project section in pyproject.toml, it identified the following problems:

$ poetry check

The Poetry configuration is invalid:
  - project.license must be valid exactly by one definition (0 matches found)
  - Either [project.version] or [tool.poetry.version] is required in package mode.

Since the license field is awkward, is not required, and is specified in the classifiers, it could be removed.

The second issue from poetry check is probably a non-issue since the version is dynamic.

@@ -14,7 +14,6 @@ keywords = [
"isolated",
"virtual",
]
license = "MIT"
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is correct according to the newer standards. The version Field is optional because can be dynamic as is here. It sounds to me like poetry has some broken checks.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yes, and no. This is a specification that is in draft, so not yet accepted however our build back end already uses it.

@gaborbernat
Copy link
Contributor

Please refer to https://peps.python.org/pep-0639/

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

Successfully merging this pull request may close these issues.

None yet

3 participants