scripts: Fix twisterlib for ruff - B905

This fixes ruff linter error B905,
where zip lacks explicit use of the
strict parameter.

Signed-off-by: Lukasz Mrugala <lukaszx.mrugala@intel.com>
This commit is contained in:
Lukasz Mrugala 2024-11-27 12:56:30 +00:00 committed by Carles Cufí
commit 29cdac06a0
2 changed files with 1 additions and 2 deletions

View file

@ -769,7 +769,6 @@
"UP031", # https://docs.astral.sh/ruff/rules/printf-string-formatting
]
"./scripts/pylib/twister/twisterlib/coverage.py" = [
"B905", # https://docs.astral.sh/ruff/rules/zip-without-explicit-strict
"E501", # https://docs.astral.sh/ruff/rules/line-too-long
"F541", # https://docs.astral.sh/ruff/rules/f-string-missing-placeholders
"SIM105", # https://docs.astral.sh/ruff/rules/suppressible-exception

View file

@ -98,7 +98,7 @@ class CoverageTool:
# Iteratively call gcov-tool (not gcov) to merge the files
merge_tool = self.gcov_tool + '-tool'
for d1, d2 in zip(dirs[:-1], dirs[1:]):
for d1, d2 in zip(dirs[:-1], dirs[1:], strict=False):
cmd = [merge_tool, 'merge', d1, d2, '--output', d2]
subprocess.call(cmd)