mirror of
https://github.com/AUTOMATIC1111/stable-diffusion-webui.git
synced 2026-03-22 22:30:45 -07:00
ci(M01): use _StubModule in loader so CamelCase attrs resolve
Made-with: Cursor
This commit is contained in:
parent
a5ebe2fe95
commit
742a713a86
1 changed files with 4 additions and 3 deletions
|
|
@ -51,11 +51,12 @@ class _StubFinder(importlib.abc.MetaPathFinder):
|
|||
|
||||
class _StubLoader(importlib.abc.Loader):
|
||||
def create_module(self, spec):
|
||||
return None
|
||||
m = _StubModule(spec.name)
|
||||
m.__path__ = []
|
||||
return m
|
||||
|
||||
def exec_module(self, module):
|
||||
# Must have __path__ so Python treats it as a package for nested imports
|
||||
module.__path__ = []
|
||||
pass
|
||||
|
||||
# Append finder so default finders run first; we catch modules they miss
|
||||
def _install_finder():
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue