You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
fix(protocols): from_data(info.to_dict()) drops the payload because to_dict omits __next_type__/__next_name__ #1447
Bug.Cls.from_data(layer.info.to_dict()) drops the payload. Info.to_dict() omits __next_type__ and __next_name__, which _make_payload dispatches on (pcapkit/protocols/protocol.py:1926). IPv6 also loses its extension headers, because __exthdr__ is dropped as well (ipv6.py:367).
Repro on main (78991b7d5), examples/captures/ipv4.pcap frame 1:
Ethernet.from_data(eth.info.to_dict()).data# 14 of 1870 octets
Layers affected: Frame, Ethernet, ARP, IPv4, IPv6, TCP and UDP, whenever the layer carries a payload.
Activity
JarryShaw commentedon Oct 9, 2026
A worker is on it now, on branch
fix/1447-to-dict-payload-roundtrip.test: capture-driven parse→rebuild and dumper round trips (#1202)
fix(protocols): from_data(info.to_dict()) drops the payload because t…
test: capture-driven parse→rebuild and dumper round trips (#1202) (#1445
fix(protocols): from_data(info.to_dict()) drops the payload because t…
fix(protocols): rebuild the payload from info.to_dict() in from_data (#…
fix(protocols): carry the dispatch keys in to_dict, guess no payload (#…
fix(protocols): find the payload by protocol name and follow IPv6 nex…