Parameters ---------- module_path : str e.g. "a.b.c.ClassName" Returns ------- Tuple[str, str] e.g. ("a.b.c", "ClassName")
(module_path: str)
| 47 | |
| 48 | |
| 49 | def split_module_path(module_path: str) -> Tuple[str, str]: |
| 50 | """ |
| 51 | |
| 52 | Parameters |
| 53 | ---------- |
| 54 | module_path : str |
| 55 | e.g. "a.b.c.ClassName" |
| 56 | |
| 57 | Returns |
| 58 | ------- |
| 59 | Tuple[str, str] |
| 60 | e.g. ("a.b.c", "ClassName") |
| 61 | """ |
| 62 | *m_path, cls = module_path.split(".") |
| 63 | m_path = ".".join(m_path) |
| 64 | return m_path, cls |
| 65 | |
| 66 | |
| 67 | def get_callable_kwargs(config: InstConf, default_module: Union[str, ModuleType] = None) -> (type, dict): |
no outgoing calls
no test coverage detected