Skip to content

const: eight more files under const/vendor ftp+http still carry the f-string disable #818

Description

@JarryShaw

Describe the bug

Eight files under pcapkit/{const,vendor}/{ftp,http}/ still carry # pylint: disable=consider-using-f-string. #817 earns it for the command.py/method.py pair; these are the remainder.

Measured on 55e1b756e:

const/ftp/return_code.py      const/http/error_code.py    const/http/frame.py
const/http/setting.py         const/http/status_code.py
vendor/ftp/return_code.py     vendor/http/frame.py        vendor/http/status_code.py  (x2)

Expected behavior

f-strings throughout, and the disable dropped from every one — at which point the claim "nothing under pcapkit/{const,vendor}/{ftp,http}/ needs it" is finally true. #804's body asserted that prematurely; #817's author caught it, and this issue is the actual remainder.

Additional context

Three of the const/ files inherit their % from a shared template, not from their own generator: const/http/{error_code,frame,setting}.py come from pcapkit/vendor/default.py:55. So converting those three means editing the shared base, which emits far more than these eight files — check the blast radius across every generated const/ module before touching it, and expect that change to want its own PR.

Two traps, both hit on this family today:

Use pylint with the real Makefile flag set plus useless-suppression to confirm each drop is earned — --disable=all --enable=useless-suppression manufactures false hits.

Related: #804, #817, #798, #783.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    constRegenerated IANA or vendor constant tables; members keep their numeric valuesrefactorRestructuring for its own sake — neither a fix nor a new capability (refactor: prefix)

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions