Skip to content

Commit 006c0a2

Browse files
authored
Ruff: Add and autofix B028 (#12024)
1 parent 81bd2c8 commit 006c0a2

File tree

4 files changed

+4
-4
lines changed

4 files changed

+4
-4
lines changed

dojo/importers/base_importer.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -243,7 +243,7 @@ def async_process_findings(
243243
ASYNC_FINDING_IMPORT_CHUNK_SIZE setting will determine how many
244244
findings will be processed in a given worker/process/thread
245245
"""
246-
warn("This experimental feature has been deprecated as of DefectDojo 2.44.0 (March release). Please exercise caution if using this feature with an older version of DefectDojo, as results may be inconsistent.")
246+
warn("This experimental feature has been deprecated as of DefectDojo 2.44.0 (March release). Please exercise caution if using this feature with an older version of DefectDojo, as results may be inconsistent.", stacklevel=2)
247247
return self.process_findings(parsed_findings, sync=False, **kwargs)
248248

249249
def determine_process_method(

dojo/importers/default_importer.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -409,7 +409,7 @@ def async_process_findings(
409409
ASYNC_FINDING_IMPORT_CHUNK_SIZE setting will determine how many
410410
findings will be processed in a given worker/process/thread
411411
"""
412-
warn("This experimental feature has been deprecated as of DefectDojo 2.44.0 (March release). Please exercise caution if using this feature with an older version of DefectDojo, as results may be inconsistent.")
412+
warn("This experimental feature has been deprecated as of DefectDojo 2.44.0 (March release). Please exercise caution if using this feature with an older version of DefectDojo, as results may be inconsistent.", stacklevel=2)
413413
chunk_list = self.chunk_findings(parsed_findings)
414414
results_list = []
415415
new_findings = []

dojo/importers/default_reimporter.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -333,7 +333,7 @@ def async_process_findings(
333333
ASYNC_FINDING_IMPORT_CHUNK_SIZE setting will determine how many
334334
findings will be processed in a given worker/process/thread
335335
"""
336-
warn("This experimental feature has been deprecated as of DefectDojo 2.44.0 (March release). Please exercise caution if using this feature with an older version of DefectDojo, as results may be inconsistent.")
336+
warn("This experimental feature has been deprecated as of DefectDojo 2.44.0 (March release). Please exercise caution if using this feature with an older version of DefectDojo, as results may be inconsistent.", stacklevel=2)
337337
# Indicate that the test is not complete yet as endpoints will still be rolling in.
338338
self.update_test_progress(percentage_value=50)
339339
chunk_list = self.chunk_findings(parsed_findings)

ruff.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -86,7 +86,7 @@ select = [
8686
"FURB",
8787
"DOC202", "DOC403", "DOC502",
8888
"RUF",
89-
"B00", "B010", "B011", "B012", "B013", "B014", "B015", "B016", "B019", "B020", "B021", "B022", "B023", "B025", "B029", "B03", "B901", "B903", "B905", "B911",
89+
"B00", "B010", "B011", "B012", "B013", "B014", "B015", "B016", "B019", "B020", "B021", "B022", "B023", "B025", "B028", "B029", "B03", "B901", "B903", "B905", "B911",
9090
]
9191
ignore = [
9292
"E501",

0 commit comments

Comments
 (0)