From ff5311df852f8d037831c02e08b7962875ea8cfc Mon Sep 17 00:00:00 2001 From: yumoqing Date: Tue, 12 Mar 2024 18:33:17 +0800 Subject: [PATCH] bugfix --- ahserver/globalEnv.py | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/ahserver/globalEnv.py b/ahserver/globalEnv.py index 76aa059..1853799 100755 --- a/ahserver/globalEnv.py +++ b/ahserver/globalEnv.py @@ -63,6 +63,8 @@ class FileOutZone(Exception): def get_config_value(kstr): keys = kstr.split('.') config = getConfig() + if config is None: + raise Exception('getConfig() error') for k in keys: config = config.get(k) if not config: @@ -70,7 +72,8 @@ def get_config_value(kstr): return config def get_definition(k): - return get_config_value(f'definition.{k}') + k = f'definitions.{k}' + return get_config_value(k) def openfile(url,m): fp = abspath(url)