Python utility library
  • Python 98.5%
  • Makefile 1.3%
  • Shell 0.2%
Find a file
Repository files (latest commit first)
Filename Latest commit message Latest commit date
Jan Lindemann 9e24a2f394
mypy: Fix fallout of warn-unreachable, exhaustive-match
Fix fallout of mypy --warn-unreachable --error-code=exchaustive-match.

The warn_unreachable and exhaustive-match mypy directives exposed several
classes of issues: unreachable statements after exhaustive matches,
unreachable isinstance checks on already-narrowed types, dead code after
raise statements, and missing None in type unions where the code
checked for it at runtime.

Fix the following files:
- Config.py: Broaden glob_paths parameter type to accept str, matching
  the isinstance check in the function body.
- ldap.py: Remove dead code (unreachable if-block with False condition
  and unreachable continue after raise).
- DataType.py: Use case _ fallback in py_type() match for exhaustive-
  match compliance, remove redundant isinstance check and assertion
  that were unreachable given type annotations.
- Event.py: Add | None to Dest type alias where the code checks for
  None at runtime.
- EventHub.py: Add | None to peer_confs variable type annotation where
  the code checks for None at runtime.
- StringTree.py: Fix is_quoted() to accept only str (not StringTree),
  fix __set() path parameter type to str | None, remove dead code after
  exhaustive isinstance checks, remove unnecessary assert.
- auth/ldap/Auth.py: Remove unreachable continue statement after raise.

Assisted-by: unsloth/Qwen3.6-35B-A3B-GGUF:IQ4_NL with pi.dev v0.82.0
Signed-off-by: Jan Lindemann <jan@janware.com>
2026-08-12 23:10:12 +00:00
.github/workflows ci.yaml: enable-email-notifications: true 2026-06-08 14:55:11 +02:00
bin Rename the MODDIR makefile variable to JWBDIR 2019-06-29 23:32:20 +02:00
conf Rename the MODDIR makefile variable to JWBDIR 2019-06-29 23:32:20 +02:00
make stree.StringTree: Add unit tests 2026-08-12 23:10:12 +00:00
scripts Add missing async keywords to jwutils.Cmd.run() reimplementations 2020-02-10 19:49:46 +01:00
src mypy: Fix fallout of warn-unreachable, exhaustive-match 2026-08-12 23:10:12 +00:00
test load_yaml: Add target path support to jw.include 2026-08-12 23:10:12 +00:00
.gitignore stree.StringTree: Add unit tests 2026-08-12 23:10:12 +00:00
HASH Release 1.0.0-50@suse-tumbleweed/x86_64 2026-06-14 23:29:46 +00:00
Makefile Makefile: Include py-topdir.mk 2026-06-12 04:55:47 +02:00
RELEASES Release 1.0.0-50@suse-tumbleweed/x86_64 2026-06-14 23:29:46 +00:00
VERSION Start version: 1.0.0-50 2026-06-14 23:08:54 +00:00