Skip to content

Commit e151113

Browse files
authored
Merge pull request #3231 from UKHSA-Internal/dependabot/pip/ruff-0.15.15
pip dev: (deps-dev): bump ruff from 0.15.12 to 0.15.15
2 parents 31b1379 + 9951b44 commit e151113

2 files changed

Lines changed: 37 additions & 25 deletions

File tree

pyproject.toml

Lines changed: 36 additions & 24 deletions
Original file line numberDiff line numberDiff line change
@@ -93,30 +93,42 @@ lint.dummy-variable-rgx = "^(_+|(_+[a-zA-Z0-9_]*[a-zA-Z0-9]+?))$"
9393
target-version = "py312"
9494

9595
[tool.ruff.lint.per-file-ignores]
96-
"**/{tests}/*" = [
97-
"E501", # Ignore line length in test files
98-
"S101", # Ignore use of `assert` statement in tests
99-
"SLF001" # Ignore access of private methods/attributes in tests
100-
]
101-
"cms/metrics_interface/interface.py" = ["PLR0904"] # Ignore maximum number of public methods
102-
"cms/dynamic_content/cards.py" = ["SLF001"] # Ignore access to protected member
103-
"cms/dynamic_content/global_filter_deconstruction.py" = ["PERF401"] # Ignore list comprehension which would reduce readibility
104-
"metrics/api/views/*" = ["E501"] # Ignore line length in API views.
105-
# This infringement is due to
106-
# swagger-facing docstrings/documentation
107-
"metrics/api/views/charts.py" = ["SIM115"] # Ignore context handler for opening file
108-
"metrics/domain/charts/chart_settings/single_category.py" = ["SIM108"] # Ignore requirement of ternary operator
109-
"**/help_texts.py" = ["W291"] # Ignore trailing whitespace for help texts
110-
"**/build_cms_site.py" = ["W605"] # Ignore escape sequences used in regex calls
111-
"ingestion/file_ingestion.py" = ["BLE001"] # Ignore blind exception catch for file ingestion function
112-
"validation/geography_code.py" = ["C901"] # Ignore complexity assessment - due to switch case
113-
"public_api/views/root_view.py" = ["A002"] # Ignore built-in `format` used in arg to extended
114-
"public_api/version_02/views/root_view.py" = ["A002"] # Ignore built-in `format` used in arg to extended
115-
# rest framework API view method
116-
"caching/public_api/crawler.py" = ["PERF401"] # Ignore list comprehension which would reduce readibility
117-
"caching/common/geographies_crawler.py" = ["PLW1641"] # Ignore requirement of `__hash__` implementation
118-
"metrics/domain/weather_health_alerts/text_lookups/*" = ["W291"] # Ignore trailing whitespace for weather alert text lookups
119-
"config.py" = ["PLW1508"] # Ignore enforcing strings for environment variables
96+
# Ignore line length in test files, use of assert statement in tests, and access of private methods/attributes in tests
97+
"**/{tests}/*" = ["E501", "S101", "SLF001"]
98+
# Ignore maximum number of public methods
99+
"cms/metrics_interface/interface.py" = ["PLR0904"]
100+
# Ignore access to protected member
101+
"cms/dynamic_content/cards.py" = ["SLF001"]
102+
# Ignore list comprehension which would reduce readibility
103+
"cms/dynamic_content/global_filter_deconstruction.py" = ["PERF401"]
104+
# Ignore line length in API views. This infringement is due to swagger-facing docstrings/documentation
105+
"metrics/api/views/*" = ["E501"]
106+
# Ignore context handler for opening file
107+
"metrics/api/views/charts.py" = ["SIM115"]
108+
# Ignore requirement of ternary operator
109+
"metrics/domain/charts/chart_settings/single_category.py" = ["SIM108"]
110+
# Ignore trailing whitespace for help texts
111+
"**/help_texts.py" = ["W291"]
112+
# Ignore escape sequences used in regex calls
113+
"**/build_cms_site.py" = ["W605"]
114+
# Ignore blind exception catch for file ingestion function
115+
"ingestion/file_ingestion.py" = ["BLE001"]
116+
# Ignore complexity assessment - due to switch case
117+
"validation/geography_code.py" = ["C901"]
118+
# Ignore built-in `format` used in arg to extended rest framework API view method
119+
"public_api/views/root_view.py" = ["A002"]
120+
# Ignore built-in `format` used in arg to extended rest framework API view method
121+
"public_api/version_02/views/root_view.py" = ["A002"]
122+
# Ignore list comprehension which would reduce readibility
123+
"caching/public_api/crawler.py" = ["PERF401"]
124+
# Ignore requirement of `__hash__` implementation
125+
"caching/common/geographies_crawler.py" = ["PLW1641"]
126+
# Ignore trailing whitespace for weather alert text lookups
127+
"metrics/domain/weather_health_alerts/text_lookups/*" = ["W291"]
128+
# Ignore enforcing strings for environment variables
129+
"config.py" = ["PLW1508"]
130+
# Ignore length of try clause
131+
"metrics/data/in_memory_models/geography_relationships/handlers.py" = ["PLW0717"]
120132

121133
[tool.ruff.lint.mccabe]
122134
# Unlike Flake8, default to a complexity level of 10.

requirements-dev.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,6 +21,6 @@ pytest-cov==7.1.0
2121
pytest-django==4.12.0
2222
pytest-random-order==1.2.0
2323
pytest-responses==0.5.1
24-
ruff==0.15.12
24+
ruff==0.15.15
2525
stevedore==5.8.0
2626
django-debug-toolbar==6.3.0

0 commit comments

Comments
 (0)