qudi
qudi copied to clipboard
In the configuration file a minus sign in names causes no clear error
If in the configuration for qudi a minus sign is used in the module name, no error is displayed in the load procedure.
For instance, if I write
hardware:
simple-data-dummy:
module.Class: 'simple_data_dummy.SimpleDummy'
I can load this file in the manager, but during the close (and save configuration) procedure of qudi, a non-transparent error occurs (saying simply that the load.cfg file could not be written).
I think that in principle it should be possible to use the minus sign, but obviously no object can be created with name simple-data-dummy
, which conflicts with python (namespace).
I know that we should not use minus signs in the names for modules (in the config file), but I would suggest to catch this error, or better raise simply an error if a minus sign is used in the name for a module.