Hacktoberfest 2026:维护者为十月标记出来的 issue,仍然开放、适合新手。 浏览 Hacktoberfest issue

Cyphal/UDP: LinkLayerSniffer shall only accept frames from a specific NIC

未关闭
#314 2 条评论 0 个 reaction 已指派 0 人 在 GitHub 查看

还没有人认领这个 Issue。

评估

难度
4/5
预计耗时
3-5 天
新手友好度
38/100
Issue 类型
缺陷
描述清晰度
基本清楚
活跃度
停滞
技术栈
python
领域
networking

调研方向

从报告中的复现命令开始,跟踪启用接口冗余时 LinkLayerSniffer 如何处理捕获。检查选择接口时涉及的 UDP tracing 和冗余传输路径。完成的标准是忽略来自其他 NICs 的帧,并且在复现的冗余接口场景中不再出现无效 transfer-ID 错误。

由索引模型根据 Issue 内容生成。

描述

class-defect domain-transport-redundant domain-transport-udp help wanted

The UDP tracer reports invalid transfer-ID errors as follows:

2023-09-01 23:54:02 1930786 DEB pycyphal.transport.redundant._tracer: RedundantTracer({(<class 'pycyphal.transport.udp._udp.UDPTransport'>, 139945704416784): <pycyphal.transport.udp._tracer.UDPTracer object at 0x7f47a4899010>, (<class 'pycyphal.transport.udp._udp.UDPTransport'>, 139945717383696): <pycyphal.transport.udp._tracer.UDPTracer object at 0x7f47a71d3b90>}): Processing RedundantCapture(timestamp=Timestamp(system_ns=1693601642728726000, monotonic_ns=993420910877439), inferior=UDPCapture(timestamp=Timestamp(system_ns=1693601642728726000, monotonic_ns=993420910877439), link_layer_packet=LinkLayerPacket(protocol=2, source=01005e001d55, destination=00248c4216fd, payload=4500003fb5a040001011e647c0a801c8ef001d55952a24a6002bcf0201043f8fffff551d3e000000000000000000008000003bfa010000000000569e7bb9a4)), iface_id=139945717383696, transfer_id_modulo=18446744073709551616)
2023-09-01 23:54:02 1930786 DEB pycyphal.transport.redundant._tracer: RedundantTracer({(<class 'pycyphal.transport.udp._udp.UDPTransport'>, 139945704416784): <pycyphal.transport.udp._tracer.UDPTracer object at 0x7f47a4899010>, (<class 'pycyphal.transport.udp._udp.UDPTransport'>, 139945717383696): <pycyphal.transport.udp._tracer.UDPTracer object at 0x7f47a71d3b90>}): BYPASS: UDPErrorTrace(timestamp=Timestamp(system_ns=1693601642728726000, monotonic_ns=993420910877439), error=<Error.UNEXPECTED_TRANSFER_ID: 2>)

Same but with manual line breaks:

2023-09-01 23:54:02 1930786 DEB pycyphal.transport.redundant._tracer:
    RedundantTracer({(<class 'pycyphal.transport.udp._udp.UDPTransport'>, 139945704416784): <pycyphal.transport.udp._tracer.UDPTracer object at 0x7f47a4899010>, (<class 'pycyphal.transport.udp._udp.UDPTransport'>, 139945717383696): <pycyphal.transport.udp._tracer.UDPTracer object at 0x7f47a71d3b90>}):
        Processing RedundantCapture(
            timestamp=Timestamp(system_ns=1693601642728726000, monotonic_ns=993420910877439),
                inferior=UDPCapture(
                    timestamp=Timestamp(system_ns=1693601642728726000, monotonic_ns=993420910877439),
                    link_layer_packet=LinkLayerPacket(
                        protocol=2,
                        source=01005e001d55,
                        destination=00248c4216fd,
                        payload=4500003fb5a040001011e647c0a801c8ef001d55952a24a6002bcf0201043f8fffff551d3e000000000000000000008000003bfa010000000000569e7bb9a4
                    )
                ),
                iface_id=139945717383696,
                transfer_id_modulo=18446744073709551616)

2023-09-01 23:54:02 1930786 DEB pycyphal.transport.redundant._tracer:
    RedundantTracer({(<class 'pycyphal.transport.udp._udp.UDPTransport'>, 139945704416784):
        <pycyphal.transport.udp._tracer.UDPTracer object at 0x7f47a4899010>, (<class 'pycyphal.transport.udp._udp.UDPTransport'>, 139945717383696): <pycyphal.transport.udp._tracer.UDPTracer object at 0x7f47a71d3b90>}):
            BYPASS:
                UDPErrorTrace(
                    timestamp=Timestamp(system_ns=1693601642728726000,
                    monotonic_ns=993420910877439),
                    error=<Error.UNEXPECTED_TRANSFER_ID: 2>
                )

Reproducible with:

UAVCAN__UDP__IFACE="127.0.0.1 192.168.1.200" UAVCAN__NODE__ID=12345 y -vv mon 2>error.log

Not reproducible without interface redundancy.

主要语言
Python
星标
142
派生
110
PR 合并指标
30 天内没有已合并 PR

环境准备

这个项目没有提供开发容器、Dockerfile 或贡献指南,环境需要你自己搭建:先看它的 README,通用步骤见我们的新手贡献指南。

从这里开始

  1. 先读完整个 Issue,再读项目的贡献指南。
  2. 在 Issue 下留言说明你要接手 —— 这能避免两个人做同样的事。
  3. Fork 仓库,在一个分支上完成修改。
  4. 提交 Pull Request,并在描述里引用这个 Issue 编号。

OpenCyphal/pycyphal 的其他 Issue

查看 OpenCyphal/pycyphal 的全部 Issue

相似的 Issue

更多 Python Issue

把新 issue 发到你的邮箱

精选适合新手参与的 GitHub issue 摘要。