Skip to content

0.10.0

Choose a tag to compare

@github-actions github-actions released this 10 Nov 06:09

Features

  • unused-ignore reports unused simplint: ignore selectors and removes them with a safe fix (#72) by @gaborbernat.
  • entrypoint-module-name reports command entrypoints in main.py or _main.py so they can move to __main__.py (#76) by @gaborbernat.
  • unguarded-entrypoint-call uses script metadata, shebangs, executable bits, and __main__.py to report trailing entrypoint calls regardless of their name. Single-line statements have an unsafe guard fix (#78) by @gaborbernat.
  • private-import-path reports private module-object imports and private imports outside a direct relative path, including nested names such as ._x._y. Tests may import names from a private module only when their package path and test_ stem match the source module (#74) by @gaborbernat.

Changes

Bug fixes

  • constant-assert leaves tuple and string literal assertions to Ruff's F631 and PLW0129 even when simplint could fix them (#77) by @gaborbernat.
  • module-variable-case leaves mixedCase names to Ruff's N816 even when simplint could rename them (#77) by @gaborbernat.
  • single-use-variable leaves yield from assignments to Ruff's RUF070 even when Ruff's fix differs (#77) by @gaborbernat.
  • single-user-constant respects Ruff's enabled local-variable limit before suggesting moving a constant into a function (#72) by @gaborbernat.
  • module-attribute-import reports private module attribute access even when Ruff selects PLC2701, which checks imports rather than attribute access (#74) by @gaborbernat.
  • missing-from-all leaves __main__.py out of the missing-export check (#72) by @gaborbernat.
  • init-module-content accepts package re-exports listed in __all__, including in applications and private subpackages (#73) by @gaborbernat.
  • init-module-content allows test package initializers, PEP 562 hooks, and TYPE_CHECKING blocks (#72) by @gaborbernat.
  • single-caller-helper avoids suggesting inlining when it would cross enabled Ruff limits for nested blocks or try statements, or trigger raise-within-try (#72) by @gaborbernat.
  • long-tuple-return respects @override return contracts when a method returns a long tuple (#72) by @gaborbernat.
  • duplicate-code compares duplicate code only within the same distribution (#72) by @gaborbernat.
  • callable-ellipsis allows callable annotations that a test body does not invoke (#72) by @gaborbernat.
  • stdlib-mock allows create_autospec imports without other patching helpers (#72) by @gaborbernat.

Deprecations

🐍 PyPI release

📜 Full Changelog