const: the four AppType registries carry a stale consider-using-f-string disable with zero %-format sites #809
Description
Activity
Checkable blocker: #803 merged.
gh pr view 803 -R JarryShaw/PyPCAPKit --json state,mergedAt#803 is
review: good-to-goand rewritespcapkit/vendor/reg/apptype/apptype.py— the file holding theTRANSPORTtemplate at:504that emits these four modules — plusconst/reg/apptype/apptype.py. Landing this first would have one rewrite discard the other's edits with no conflict marker.Also note #806 will regenerate or hand-edit the same four registry files for the
protoretyping, so if #806 starts before this lands, fold this in there rather than running both. Chain: #803 → this issue, with #806 as the item to coordinate with.- addedrefactorRestructuring for its own sake — neither a fix nor a new capability (refactor: prefix)Restructuring for its own sake — neither a fix nor a new capability (refactor: prefix)constRegenerated IANA or vendor constant tables; members keep their numeric valuesRegenerated IANA or vendor constant tables; members keep their numeric valuesblockedDeferred pending another issue or decision; see the last comment for what unblocks itDeferred pending another issue or decision; see the last comment for what unblocks it
on Sep 25, 2026 #803 merged, so the original blocker has cleared — but this now waits on #806 instead. Re-blocked rather than opened.
Checkable blocker: #806 merged.
gh issue view 806 -R JarryShaw/PyPCAPKit --json state#806 retypes
AppType.protoacross all four registry files —pcapkit/const/reg/apptype/{tcp,udp,sctp,dccp}.py— and edits thevendor/reg/apptype/apptype.pytemplate that emits them, which is where the stale disable originates (theTRANSPORTtemplate). A worker is on #806 now. Doing this first would have #806's rewrite discard it.Fold this in with #806 if convenient, since it is four const files plus one template line and #806 is already rewriting all five. Otherwise it unblocks the moment #806 lands. Re-derive the
:504citation againstorigin/main(4530424df) — #803 moved that file.- addedwipWork in flight - a covering PR is open or an agent is actively on itWork in flight - a covering PR is open or an agent is actively on itand removedblockedDeferred pending another issue or decision; see the last comment for what unblocks itDeferred pending another issue or decision; see the last comment for what unblocks it
on Sep 26, 2026 - removedwipWork in flight - a covering PR is open or an agent is actively on itWork in flight - a covering PR is open or an agent is actively on it
on Sep 26, 2026
Metadata
Metadata
Assignees
Labels
Projects
- StatusShow more project fieldsDone
Describe the bug
The four generated
AppTyperegistries each carry# pylint: disable=consider-using-f-stringwhile containing zero%-format sites, so the suppression is stale. Found by #803's cross-review, confirmed genuinely stale with pylint'suseless-suppressionrather than inferred from a grep.Expected behavior
The disable dropped from all four, and from whatever emits it, so the suppression is earned everywhere in this family.
Additional context
The source is the fifth template, which #803 deliberately did not touch.
TRANSPORTatpcapkit/vendor/reg/apptype/apptype.py:504emits the four registry modules; #803's title scopes to "the four bespoke templates" and this is a fifth. So this is not a #803 regression — the disable is identically stale onmain— it is the remainder of #798's "the disable being earned is the cheapest signal the work is unfinished" argument, applied one template further out.make pylintcannot see this.useless-suppressionis not in the Makefile's--enableset, so the staleness is invisible to CI and will stay invisible after this is fixed. Worth deciding whether to add it while here — that would catch the next stale disable for free, and it is the check that found this one.Two traps, both hit while establishing this:
%-format grep must allow both quote styles and multi-line strings. A pattern requiring single quotes reported 0 for files whose every site was double-quoted. The review used an AST walk overBinOp(Constant(str) % x)and self-tested it against known positives including a double-quoted and a triple-quoted case.pylint --disable=all --enable=useless-suppressionmanufactures false hits — the review's first run produced bogusline-too-long/no-memberreports that way. Use the real Makefile flag set plususeless-suppression.Related: #798, #803, #804, #783.