diff --git a/secop_psi/sea.py b/secop_psi/sea.py index 869633d..e66bd17 100644 --- a/secop_psi/sea.py +++ b/secop_psi/sea.py @@ -401,9 +401,8 @@ class SeaModule(Module): include = True for paramdesc in descr['params']: path = paramdesc['path'] - if paramdesc.get('visibility', 1) > visibility_level: - if not path.endswith('is_running'): - continue + if paramdesc.get('visibility', 1) > visibility_level and not path.endswith('is_running'): + continue sub = path.split('/', 1) if rpath == '.': # take all except subpaths with readonly node at top if len(sub) == 1: @@ -413,9 +412,11 @@ class SeaModule(Module): elif sub[0] == rpath: result.append(paramdesc) descr['params'] = result - if result[0]['path'] != '': - pass # TODO: check these cases - result[0]['key'] = 'value' + rel0 = '' if rel_paths[0] == '.' else rel_paths[0] + if result[0]['path'] == rel0: + result[0]['key'] = 'value' + else: + logger.error('%s: no value found', name) # logger.info('PARAMS %s %r', name, result) base = descr['base'] params = descr['params']