Skip to content

docs(const,vendor): Method.get cites RFC 959 §4 for a case-insensitivity rule stated in §5.3 #947

Description

@JarryShaw

Describe the bug

Method.get's docstring explains its own case-sensitivity by contrast with FTP, and cites the wrong section of RFC 959 for the contrast:

pcapkit/const/http/method.py:268      pcapkit/vendor/http/method.py:173
    case-insensitive because :rfc:`959#section-4` says FTP
    command codes are not.

RFC 959 §4 is FILE TRANSFER FUNCTIONS and contains no case-sensitivity language at all. The statement is in §5.3 COMMANDS:

The command codes are four or fewer alphabetic characters. Upper and lower case alphabetic characters are to be treated identically.

Reproduction

$ curl -s -A 'Mozilla/5.0' -L https://www.rfc-editor.org/rfc/rfc959.html -o rfc959.html
$ grep -n -i 'upper and lower' rfc959.html
2469:      Upper and lower case alphabetic characters are to be treated
$ grep -n 'id="section-4"\|id="section-5"\|id="section-6"' rfc959.html
1329:...id="section-4"...4.  FILE TRANSFER FUNCTIONS
2333:...id="section-5"...5.  DECLARATIVE SPECIFICATIONS
2920:...id="section-6"...6.  STATE DIAGRAMS
$ grep -n '5\.3\.  COMMANDS' rfc959.html
2458:   5.3.  COMMANDS

Line 2469 sits between section-5 (2333) and section-6 (2920), so it is inside §5, not §4. That is the only such sentence in the document — note it wraps across lines 2469-2470, so a single-line grep for treated identically finds nothing.

Expected behavior

:rfc:959#section-5``, which is the finest anchor RFC 959 renders (only section-1..`section-8` exist, per #944). Alternatives: `#page-45`, where §5.3 begins, or leave `#section-4` and reword the prose to stop attributing the claim to a section that does not make it.

Notes

System information

  • pcapkit commit 210bdb419, Python 3.14.7, CPython, Linux.

No activity

Activity on this issue will appear here.

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

    bugIssues reporting a defect (set by the bug report template; a default, not an assessment)constRegenerated IANA or vendor constant tables; members keep their numeric valuesdocsPull requests that change documentation only (docs: subject prefix)

    Projects

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions