forked from M-Labs/artiq
1
0
Fork 0

Fix rtiomap failure on device aliases

Signed-off-by: Egor Savkin <es@m-labs.hk>
This commit is contained in:
Egor Savkin 2022-12-13 11:11:15 +08:00 committed by Sébastien Bourdeauducq
parent 2a58981822
commit d75ade7be6
1 changed files with 1 additions and 1 deletions

View File

@ -29,7 +29,7 @@ def get_argparser():
def get_rtio_channels(desc): def get_rtio_channels(desc):
if desc["type"] == "local": if isinstance(desc, dict) and desc["type"] == "local":
module = importlib.import_module(desc["module"]) module = importlib.import_module(desc["module"])
device_class = getattr(module, desc["class"]) device_class = getattr(module, desc["class"])
return getattr(device_class, "get_rtio_channels", lambda **kwargs: [])(**desc.get("arguments", {})) return getattr(device_class, "get_rtio_channels", lambda **kwargs: [])(**desc.get("arguments", {}))