Skip to content

Run ruff on tests#1080

Draft
DimitriPapadopoulos wants to merge 24 commits into
pydicom:mainfrom
DimitriPapadopoulos:exclude_tests
Draft

Run ruff on tests#1080
DimitriPapadopoulos wants to merge 24 commits into
pydicom:mainfrom
DimitriPapadopoulos:exclude_tests

Conversation

@DimitriPapadopoulos
Copy link
Copy Markdown
Contributor

Reference issue

Do not exclude tests form linter checks. It finds actual errors in tests.

Tasks

  • Unit tests added that reproduce issue or prove feature is working
  • Fix or feature added
  • Documentation and examples updated (if relevant)
  • Unit tests passing and coverage at 100% after adding fix/feature
  • Type annotations updated and passing with mypy
  • Apps updated and tested (if relevant)

DimitriPapadopoulos and others added 24 commits March 8, 2026 14:47
Pointless comparison at end of function scope. Did you mean to return the expression result?
Found useless expression. Either assign it to a variable or remove it.
`zip()` without an explicit `strict=` parameter
Unnecessary list comprehension (rewrite as a set comprehension)
Unnecessary dict comprehension for iterable; use `dict.fromkeys` instead
Implicitly concatenated string literals on one line
Explicitly concatenated string should be implicitly concatenated
Use `typing.NamedTuple` instead of `collections.namedtuple`
Comparison to `None` should be `cond is None`
Avoid equality comparisons to `True`; use `item.response_requested:` for truth checks
Test for membership should be `not in`
Do not use bare `except`
Ambiguous variable name: `l`
Imported but unused
`from ... import *` used; unable to detect undefined names
Name may be undefined, or defined from star imports
f-string without any placeholders
Redefinition of unused name
Local variable is assigned to but never used
Use f-string instead of `format` call
Version block is outdated for minimum Python version
@DimitriPapadopoulos DimitriPapadopoulos marked this pull request as draft March 8, 2026 15:07
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant