OpenCyphal / pycyphal

Python implementation of the Cyphal protocol stack.
https://pycyphal.readthedocs.io/
MIT License
117 stars 105 forks source link

Remove a version restriction from lipbcap #247

Closed silverv closed 1 year ago

silverv commented 1 year ago

The < 2.0.0 requirement on version remains for safety reasons. This allows Yukon to specify its own (lower) version of libpcap. Yukon requires an older version because the newer version causes a runtime issue in a built exe file on Windows because of some recursive import of pkg-about.

Here is the error stack trace from Yukon that caused this pull request to happen here:

2022-09-13 19:58:37,428 0002828 INF: C:\Users\silver\AppData\Local\Temp\_MEI8722\yukon\services\api.pyc: Error: Traceback (most recent call last):
  File "importlib_metadata\__init__.py", line 564, in from_name
StopIteration

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "services\cyphal_worker.py", line 43, in _internal_method
  File "pycyphal\transport\redundant\_redundant_transport.py", line 168, in attach_inferior
  File "pycyphal\transport\udp\_udp.py", line 287, in begin_capture
  File "pycyphal\transport\udp\_ip\_v4.py", line 142, in make_sniffer
  File "pycyphal\transport\udp\_ip\_v4.py", line 151, in __init__
  File "pycyphal\transport\udp\_ip\_link_layer.py", line 122, in __init__
  File "pycyphal\transport\udp\_ip\_link_layer.py", line 341, in _find_devices
  File "PyInstaller\loader\pyimod02_importers.py", line 493, in exec_module
  File "libpcap\__init__.py", line 5, in <module>
  File "PyInstaller\loader\pyimod02_importers.py", line 493, in exec_module
  File "libpcap\__about__.py", line 5, in <module>
  File "PyInstaller\loader\pyimod02_importers.py", line 493, in exec_module
  File "pkg_about\__init__.py", line 5, in <module>
  File "PyInstaller\loader\pyimod02_importers.py", line 493, in exec_module
  File "pkg_about\__about__.py", line 5, in <module>
  File "pkg_about\_about.py", line 16, in about
  File "importlib_metadata\__init__.py", line 1005, in metadata
  File "importlib_metadata\__init__.py", line 566, in from_name
importlib_metadata.PackageNotFoundError: No package metadata was found for pkg_about