Skip to content

Commit

Permalink
Enable complexity check and pycodestyle warnings. Closes #110.
Browse files Browse the repository at this point in the history
  • Loading branch information
jaraco committed Mar 2, 2024
1 parent 779219c commit d1c5444
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions ruff.toml
Original file line number Diff line number Diff line change
@@ -1,4 +1,8 @@
[lint]
select = [
"C901",
"W",
]
ignore = [
# https://docs.astral.sh/ruff/formatter/#conflicting-lint-rules
"W191",
Expand Down

4 comments on commit d1c5444

@jaraco
Copy link
Owner Author

@jaraco jaraco commented on d1c5444 Mar 2, 2024

Choose a reason for hiding this comment

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

Hmm. I'm now beginning to think this change disabled the default checks :(.

@DimitriPapadopoulos
Copy link
Contributor

Choose a reason for hiding this comment

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

@jaraco Note that W rules are redundant when using a formatter (the ruff formatter?). At least that's what the Scientific Python Library Development Guide suggests, I haven't checked for myself:

E, F, W: These are the standard flake8 checks, classic checks that have stood the test of time. Not required if you use extend-select (W not needed if you use a formatter)

@DimitriPapadopoulos
Copy link
Contributor

Choose a reason for hiding this comment

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

Perhaps change C901C90? It's currently equivalent, since the C90 ruleset contains the single C901 rule.

@jaraco
Copy link
Owner Author

@jaraco jaraco commented on d1c5444 Mar 7, 2025

Choose a reason for hiding this comment

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

For some reason, the GitHub website isn't working for me (quote reply and reference in new issue do nothing). I'll troubleshoot that later. In the meantime, I committed b00e9dd for the W rules.

For C901 vs C90, I don't have any opinion. Let's leave it unchanged until it has a meaningful effect.

Please sign in to comment.