Skip to content
This repository has been archived by the owner on Jun 11, 2024. It is now read-only.

[pre-commit.ci] pre-commit autoupdate #178

Merged
merged 2 commits into from
May 20, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions .pre-commit-config.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -29,12 +29,12 @@ repos:
- tomli

- repo: https://github.com/tox-dev/pyproject-fmt
rev: "2.0.3"
rev: "2.1.1"
hooks:
- id: pyproject-fmt

- repo: https://github.com/abravalheri/validate-pyproject
rev: v0.17
rev: v0.18
hooks:
- id: validate-pyproject

Expand Down
75 changes: 36 additions & 39 deletions pyproject.toml
Original file line number Diff line number Diff line change
@@ -1,33 +1,4 @@
[tool.ruff]
lint.dummy-variable-rgx = "^(_+|(_+[a-zA-Z0-9_]*[a-zA-Z0-9]+?))$" # Regular expression for dummy variables
lint.ignore = [
"B904", # Within an `except` clause, raise exceptions with `raise ... from err`
"B905", # `zip()` without an explicit `strict=` parameter
"E501", # Line too long
"E741", # Ambiguous variable name 'l'
"G004", # Logging statement uses f-string
"N999", # Invalid module name
"PLR2004", # Magic value used in comparison
"PLR5501", # Consider using `elif` instead of `else`
"PLW0120", # `else` clause on loop without a `break` statement
"PLW060", # Using global for `{name}` but no assignment is done -- DO NOT FIX
"PLW2901", # Redefined loop variable
"RUF00", # Ambiguous unicode character -- DO NOT FIX
"RUF100", # Unused `noqa` directive
"S101", # Use of `assert` detected -- DO NOT FIX
"S105", # Possible hardcoded password: 'password'
"S113", # Probable use of requests call without timeout
"S311", # Standard pseudo-random generators are not suitable for cryptographic purposes
"UP038", # Use `X | Y` in `{}` call instead of `(X, Y)` -- DO NOT FIX
"N806", # Variable name should be lowercase
"A001",
"A002", # Shadowing variable names
"A003", # Class attribute shadowing
"N803", # Variable name should be lowercase
"N802", # Function name should be lowercase
"S324",
"B006",
]
lint.select = [
"A", # builtins
"B", # bugbear
Expand All @@ -38,8 +9,8 @@ lint.select = [
"G", # logging format
"I", # isort
"N", # pep8 naming
"PL", # pylint
"PIE", # pie
"PL", # pylint
"PYI", # type hinting stub files
"RUF", # ruff
"S", # bandit
Expand All @@ -49,19 +20,45 @@ lint.select = [
"YTT", # year 2020
]

[tool.ruff.lint.mccabe] # DO NOT INCREASE THIS VALUE
max-complexity = 17 # default: 10

[tool.ruff.lint.pylint] # DO NOT INCREASE THESE VALUES
allow-magic-value-types = [
lint.dummy-variable-rgx = "^(_+|(_+[a-zA-Z0-9_]*[a-zA-Z0-9]+?))$" # Regular expression for dummy variables
lint.mccabe.max-complexity = 17 # default: 10
lint.pylint.allow-magic-value-types = [
"float",
"int",
"str",
]
max-args = 10 # default: 5
max-branches = 20 # default: 12
max-returns = 8 # default: 6
max-statements = 88 # default: 50
lint.pylint.max-args = 10 # default: 5
lint.pylint.max-branches = 20 # default: 12
lint.pylint.max-returns = 8 # default: 6
lint.pylint.max-statements = 88 # default: 50
lint.ignore = [
"A001",
"A002", # Shadowing variable names
"A003", # Class attribute shadowing
"B006",
"B904", # Within an `except` clause, raise exceptions with `raise ... from err`
"B905", # `zip()` without an explicit `strict=` parameter
"E501", # Line too long
"E741", # Ambiguous variable name 'l'
"G004", # Logging statement uses f-string
"N802", # Function name should be lowercase
"N803", # Variable name should be lowercase
"N806", # Variable name should be lowercase
"N999", # Invalid module name
"PLR2004", # Magic value used in comparison
"PLR5501", # Consider using `elif` instead of `else`
"PLW060", # Using global for `{name}` but no assignment is done -- DO NOT FIX
"PLW0120", # `else` clause on loop without a `break` statement
"PLW2901", # Redefined loop variable
"RUF00", # Ambiguous unicode character -- DO NOT FIX
"RUF100", # Unused `noqa` directive
"S101", # Use of `assert` detected -- DO NOT FIX
"S105", # Possible hardcoded password: 'password'
"S113", # Probable use of requests call without timeout
"S311", # Standard pseudo-random generators are not suitable for cryptographic purposes
"S324",
"UP038", # Use `X | Y` in `{}` call instead of `(X, Y)` -- DO NOT FIX
]

[tool.codespell]
ignore-words-list = "3rt,ans,crate,damon,fo,followings,hist,iff,kwanza,mater,secant,som,sur,tim,zar"
Expand Down
Loading