diff --git a/linux/keyman-config/keyman_config/gsettings.py b/linux/keyman-config/keyman_config/gsettings.py index e0b0726b6fa..1a767c479d0 100644 --- a/linux/keyman-config/keyman_config/gsettings.py +++ b/linux/keyman-config/keyman_config/gsettings.py @@ -74,10 +74,13 @@ def get(self, key): else: process = subprocess.run(args, capture_output=True) if process.returncode == 0: - value = eval(process.stdout) - else: - value = None - logging.warning('Could not convert to sources') + output = process.stdout + if output.decode('utf-8').startswith('['): + value = eval(output) + return value + + logging.debug('Could not convert to sources') + return None else: variant = self.schema.get_value(key) value = self._convert_variant_to_array(variant)