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

Lint pyproject.toml according to the 'Declaring project metadata' spec #1472

Closed
not-my-profile opened this issue Dec 30, 2022 · 5 comments
Closed
Labels
rule Implementing or modifying a lint rule

Comments

@not-my-profile
Copy link
Contributor

not-my-profile commented Dec 30, 2022

Declaring project metadata (based on PEP 621) defines how metadata in pyproject.toml should be defined. Unless I am missing something there doesn't appear to be an existing lint plugin we could model this after, which would make this a RUF check.

This is basically the same idea as rust-lang/rust-clippy/issues/6431 but for Python/pyproject.toml/ruff instead of Rust/Cargo.toml/clippy.

Sidenote: Maybe we want to use pyproject-toml-rs for the parsing step?

@charliermarsh
Copy link
Member

(I know there's validate-pyproject but it may not be relevant at all, I haven't looked closely.)

@not-my-profile
Copy link
Contributor Author

Oh, yes I did miss that ... it does appear to be relevant. Although our checks could probably be more in-depth.

@charliermarsh
Copy link
Member

(I really haven't looked at that project at all, it was just the first thing that came to mind, maybe unhelpful...)

@JonathanPlasse
Copy link
Contributor

JonathanPlasse commented Mar 4, 2023

There is also taplo that is more general which is

A TOML parser, analyzer and formatter library

@JonathanPlasse
Copy link
Contributor

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
rule Implementing or modifying a lint rule
Projects
None yet
Development

No branches or pull requests

3 participants