MCPcopy Create free account
hub / github.com/dask/dask / register_lazy

Method register_lazy

dask/utils.py:731–741  ·  view source on GitHub ↗

Register a registration function which will be called if the *toplevel* module (e.g. 'pandas') is ever loaded.

(self, toplevel, func=None)

Source from the content-addressed store, hash-verified

729 return wrapper(func) if func is not None else wrapper
730
731 def register_lazy(self, toplevel, func=None):
732 """
733 Register a registration function which will be called if the
734 *toplevel* module (e.g. 'pandas') is ever loaded.
735 """
736
737 def wrapper(func):
738 self._lazy[toplevel] = func
739 return func
740
741 return wrapper(func) if func is not None else wrapper
742
743 def dispatch(self, cls):
744 """Return the function implementation for the given ``cls``"""

Callers

nothing calls this directly

Calls 1

wrapperFunction · 0.70

Tested by

no test coverage detected