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

Ruff misconfiguration #152

Closed
abravalheri opened this issue Oct 30, 2024 · 4 comments
Closed

Ruff misconfiguration #152

abravalheri opened this issue Oct 30, 2024 · 4 comments

Comments

@abravalheri
Copy link
Contributor

Right now, if I try to run pipx run --python python3.12 ruff check on the setuptools codebase I get the following error:

ruff failed
  Cause: Failed to parse /home/abravalheri/workspace/setuptools/ruff.toml
  Cause: TOML parse error at line 2, column 11
  |
2 | include = "pyproject.toml"
  |           ^^^^^^^^^^^^^^^^
invalid type: string "pyproject.toml", expected a sequence

The same error shows up in skeleton's CI: https://github.com/jaraco/skeleton/actions/runs/11558298719/job/32170335213.

Probably it should be include = ["pyproject.toml"]?

The configuration was introduced in e61a9df.

@abravalheri
Copy link
Contributor Author

According to @Avasam in pypa/setuptools#4718 (comment), even if we fix the "syntax" of the include field, the presence of it still cause other problems.

Another temporary, workaround while astral-sh/ruff#10299 is not handled is to explicitly use target-version = "py39" # Target the oldest supported Python version as pointed out in the comment linked above.

@jaraco
Copy link
Owner

jaraco commented Nov 2, 2024

Looking at #119, I think I confused myself and it should have been "extend" and not "include".

jaraco added a commit to jaraco/jaraco.xonsh that referenced this issue Nov 2, 2024
@jaraco jaraco closed this as completed in d778f26 Nov 2, 2024
@jaraco
Copy link
Owner

jaraco commented Nov 2, 2024

Sorry for the disruption

jaraco added a commit that referenced this issue Nov 2, 2024
@Avasam
Copy link
Contributor

Avasam commented Nov 2, 2024

Looking at #119, I think I confused myself and it should have been "extend" and not "include".

Oh wow, I didn't catch on either... Of course Ruff shows no error if you only include a non-python file >.<

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