MCPcopy Create free account
hub / github.com/apache/fory / ModulePlaceholder

Class ModulePlaceholder

python/pyfory/utils.py:69–80  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

67
68
69class ModulePlaceholder:
70 def __init__(self, mod_name: str):
71 self._mod_name = mod_name
72
73 def _raises(self):
74 raise AttributeError(f"{self._mod_name} is required but not installed.")
75
76 def __getattr__(self, key):
77 self._raises()
78
79 def __call__(self, *_args, **_kwargs):
80 self._raises()
81
82
83is_little_endian = sys.byteorder == "little"

Callers 1

lazy_importFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected