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(utilities): concurrent first access to lazy protocol exports deadlocks the import system #2771
Describe the bug
Since #2757, threads that reach different lazy exports of pcapkit.protocols at the same time on a cold import deadlock the import system: _DeadlockError: deadlock detected by _ModuleLock('pcapkit.protocols.link.arp.data'). 1.5.1 imported these eagerly, so this is a regression on main. Reaching a single name from many threads does not trigger it.
Expected behavior
Concurrent first access resolves every name, as the eager 1.5.1 imports did.
Additional context
The threads take per-module import locks in different orders, and the protocol/schema/data modules import each other. A likely fix is to serialise first resolution in the shared pcapkit.utilities.importlib.lazy_exports hook, rather than per package. The #2757 thread test only raced on the registry.
Activity
fix(protocols): resolve the remaining member and helper imports under…
fix(utilities): serialise first resolution of lazy exports and module…