Unverified Commit 58842057 authored by Philip Meier's avatar Philip Meier Committed by GitHub
Browse files

fix mypy (#7685)

parent 016804ee
......@@ -122,7 +122,9 @@ def get_weight(name: str) -> WeightsEnum:
base_module_name = ".".join(sys.modules[__name__].__name__.split(".")[:-1])
base_module = importlib.import_module(base_module_name)
model_modules = [base_module] + [
x[1] for x in inspect.getmembers(base_module, inspect.ismodule) if x[1].__file__.endswith("__init__.py")
x[1]
for x in inspect.getmembers(base_module, inspect.ismodule)
if x[1].__file__.endswith("__init__.py") # type: ignore[union-attr]
]
weights_enum = None
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment