From 54c9fb9db972ad5a3332228c88137dcfd025170a Mon Sep 17 00:00:00 2001 From: zebra Date: Tue, 3 Jun 2025 11:43:43 +0200 Subject: [PATCH] SEA: again a fix - commits before damaged 'mf' of MA10 --- cfg/main/ori4_cfg.py | 2 +- frappy_psi/sea.py | 10 +++------- 2 files changed, 4 insertions(+), 8 deletions(-) diff --git a/cfg/main/ori4_cfg.py b/cfg/main/ori4_cfg.py index 954559b..1ca49e0 100644 --- a/cfg/main/ori4_cfg.py +++ b/cfg/main/ori4_cfg.py @@ -14,7 +14,7 @@ Mod('sea_main', # io='sea_main', # meaning=['temperature_regulation', 27], # sea_object='tt', -# rel_paths=['.', 'tm', 'set', 'dblctrl'], +# rel_paths=['tm', '.', 'set', 'dblctrl'], #) Mod('tt', diff --git a/frappy_psi/sea.py b/frappy_psi/sea.py index 5790bdc..cc601c8 100644 --- a/frappy_psi/sea.py +++ b/frappy_psi/sea.py @@ -557,16 +557,12 @@ class SeaModule(Module): else: cls.paramFilter(result, paramdesc) cfgdict.pop('rel_paths', None) - # take top parameters - we do not want them first - top = result.pop('.', None) params = [] for key, plist in result.items(): - params.extend(plist) # the first value contains the main value - if top: - params.extend(top) # no we can add top parameters - top = None + params.extend(plist) if is_running: # take this at end params.append(is_running) + # this needs some care in the configuration: the main value must be the first! main_value = params[0] if issubclass(cls, Readable): if 'key' in main_value: @@ -717,7 +713,7 @@ class SeaModule(Module): @classmethod def paramFilter(cls, result, paramdesc): sub = paramdesc['path'].split('/', 1) - sublist = result.get(sub[0]) + sublist = result.get(sub[0] or '.') if sublist is None: sublist = result.get('.') if sublist is None: