-
-
Notifications
You must be signed in to change notification settings - Fork 1.3k
Adequate to newly introduced Ruff checks #5042
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
Conversation
|
@@ -165,7 +165,7 @@ def test_excluded_subpackages(tmpdir_cwd): | |||
build_py = dist.get_command_obj("build_py") | |||
|
|||
msg = r"Python recognizes 'mypkg\.tests' as an importable package" | |||
with pytest.warns(SetuptoolsDeprecationWarning, match=msg): | |||
with pytest.warns(SetuptoolsDeprecationWarning, match=msg): # noqa: PT031 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Given the TODO comment I find this acceptable
@@ -73,6 +73,7 @@ ignore = [ | |||
# Suppress nuisance warnings about module-import-not-at-top-of-file (E402) due to workaround for #4476 | |||
"setuptools/__init__.py" = ["E402"] | |||
"pkg_resources/__init__.py" = ["E402", "ANN204"] | |||
"pkg_resources/tests/test_resources.py" = ["PT031"] |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Given pkg_resources
is planned for removal, I'm not even gonna bother checking what this triggered on ^^
@@ -1,6 +1,6 @@ | |||
repos: | |||
- repo: https://github.com/astral-sh/ruff-pre-commit | |||
rev: v0.9.9 | |||
rev: v0.12.0 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I understand pre-commit (the tool) can be useful to some devs to install git pre-commit hooks. But considering we don't use it on the CI, we should really consider just making it run a "tox autofix" command to avoid having to duplicate versions here.
Then if we want CI autofixes, https://autofix.ci/ and https://pre-commit.ci/lite both do more or less the same job (pushes any local changes during a CI run)
At that point, .pre-commit-config.yaml
would only be provided out of convenience for those who enjoy pre-commit hooks and don,t want to manually setup a hook to run said "tox autofix" command.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Agreed, I added reported this to skeleton
and added a note to the PR saying that I don't have many strong opinions about it.
@cclauss Interesting this is yet another case of dependency updates in the last days... I suppose what is happening is that there are no pre-build ctracers available for Cygwin so it fails with an exception? Not sure is there something we can do in the short term. Let me try to ignore the warning in the (I believe that the cygwin failure is not blocking ATM) |
Summary of changes
This should avoid the CI failing on unrelated changes.
Closes
Pull Request Checklist
newsfragments/
.(See documentation for details)