Commit 36aa406
authored
Fix 1840 (#1895)
* start new dev branch; add audit file
* Add ruff ANN/UP/TCH annotation checks to check-typing (#1840)
The check-typing recipe now runs `ruff check --select ANN,UP,TCH` (annotation
presence, pyupgrade modern syntax, TYPE_CHECKING imports) on src/autobahn/
before the ty check, so annotation/style regressions are caught in the CI
quality-checks job.
src/autobahn/ currently has ~3800 missing-annotation findings, so the ANN
codes (and the 3 TC00x currently present) are ratcheted via an explicit
--ignore allowlist to be removed module-by-module (#1839); every other UP and
TC rule is enforced immediately. Generated code (flatbuffers/, wamp/gen/,
message_fbs.py) is excluded via [tool.ruff] plus --force-exclude.
Deviation from the issue as written: the annotation rules are scoped to this
recipe via the command-line --select rather than the global
[tool.ruff.lint] select, because check-format runs `ruff check .` off that
config and would otherwise turn red with all ~3800 findings. The proposed
`required-imports = ["from __future__ import annotations"]` is also omitted
(it is the eager annotation-eval hazard behind #1878). Only the safe
[tool.ruff.lint.flake8-annotations] tuning was added to pyproject.toml.
check-typing now also depends on (install-tools venv) so the venv ruff is
present when run standalone. Verified green end-to-end (ruff + ty) on cpy311.
Note: This work was completed with AI assistance (Claude Code).1 parent 20821ab commit 36aa406
4 files changed
Lines changed: 31 additions & 1 deletion
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
| 1 | + | |
| 2 | + | |
| 3 | + | |
| 4 | + | |
| 5 | + | |
| 6 | + | |
| 7 | + | |
| 8 | + | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
16 | 16 | | |
17 | 17 | | |
18 | 18 | | |
| 19 | + | |
19 | 20 | | |
20 | 21 | | |
21 | 22 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
730 | 730 | | |
731 | 731 | | |
732 | 732 | | |
733 | | - | |
| 733 | + | |
734 | 734 | | |
735 | 735 | | |
736 | 736 | | |
| |||
740 | 740 | | |
741 | 741 | | |
742 | 742 | | |
| 743 | + | |
| 744 | + | |
| 745 | + | |
| 746 | + | |
| 747 | + | |
| 748 | + | |
| 749 | + | |
| 750 | + | |
| 751 | + | |
| 752 | + | |
| 753 | + | |
| 754 | + | |
| 755 | + | |
| 756 | + | |
743 | 757 | | |
744 | 758 | | |
745 | 759 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
381 | 381 | | |
382 | 382 | | |
383 | 383 | | |
| 384 | + | |
| 385 | + | |
| 386 | + | |
| 387 | + | |
| 388 | + | |
| 389 | + | |
| 390 | + | |
0 commit comments