OpenCyphal / pycyphal

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

Needs remove_import_hooks #270

Open silverv opened 1 year ago

silverv commented 1 year ago

It should do something like this:

for meta_path in sys.meta_path.copy():
    if isinstance(meta_path, DsdlMetaFinder):
        sys.meta_path.remove(meta_path)

It should be available in the __init__.py file in the pycyphal.dsdl module

pavel-kirienko commented 6 months ago

Also, install_import_hook needs to be renamed into add_import_hook and the old name should be deprecated. The docs need to make it clear that the function does not modify the existing import hooks.