Skip to content

fix(tests): the schema round trip cannot reparse DTLSCIDCiphertext, failing main's Python 3.15 leg #2645

Closed

Description

@JarryShaw

The required Python 3.15 leg on main (18544c3c9, Unit Tests run 41401136086) fails two subtests of tests/corekit/test_schema_roundtrip_unit.py:

  • test_minimal_instance_round_trips, case application.dtls:DTLSCIDCiphertext: REPARSE: KeyError: '__cid_length__'
  • test_patterned_instance_round_trips, case application.dtls:DTLSCIDCiphertext/patterned: UNBUILT

The schema arrived with #2631. Its cid field takes its length from the __cid_length__ key of the packet context, which the DTLS parser supplies. Probably the round-trip harness supplies no such context when it reparses. The fix is to give the harness that context, or to change the schema if the round trip shows a real defect. The fix must not hide the case in KNOWN_FAILURES.

#2643 adds a DTLS 1.3 header whose field reads the same key, so it will need the same treatment once it rebases. The other failure on this leg (test_package_reexports_1807_unit) is fixed by #2641.

Activity

  1. added this to the PyPCAPKit v1.6 milestone on Nov 2, 2026
  2. added
    bugIssues reporting a defect (set by the bug report template; a default, not an assessment)
    wipWork in flight - a covering PR is open or an agent is actively on it
    on Nov 2, 2026
  3. JarryShaw commented on Nov 2, 2026

    @JarryShaw
    OwnerAuthor

    Landed on main as 16ccc4373 (test-only). The schema is correct: the CID length is not carried in the record, so the parser passes it as context. The gap was in the harness, which finds missing context from a KeyError while packing. pre_pack derives this key itself, so packing never reported it, and only the reparse read it. A new PARSE_CONTEXT table gives the reparse that context, and the case now carries a non-empty CID.

    Only the 3.15 leg failed because the module is LATEST-tier. The bug is not version-specific: it reproduces on 3.14.

    #2643's DTLS 1.3 header reads the same key, so it needs a PARSE_CONTEXT entry when it rebases.

  4. removed
    wipWork in flight - a covering PR is open or an agent is actively on it
    on Nov 2, 2026
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)

    Projects

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions