andes.system.config_runtime.SystemConfigRuntime#
- class andes.system.config_runtime.SystemConfigRuntime(system)[source]#
Manage system-level configuration bootstrapping and persistence.
Configuration is resolved in four phases, each with higher priority:
load_rc()— load from~/.andes/andes.rcmerge_file_config()— merge_configsection from the case fileapply_cli_overrides()— applyconfig_optionfrom the CLIfinalize()— createsystem.config, add defaults, validate
Phases are called in order from
andes.system.facade.System.__init__().Methods
apply_cli_overrides()Phase 3: Apply
config_optionfrom the command line intosystem._config_object.collect_config()Collect config data from models into a
ConfigParser.collect_config_rows()Collect all config values as a flat list of row dicts for serialization to
_configsheets/keys.configure_numpy([seed, divide, invalid])Configure NumPy based on Config.
finalize([config])Phase 4: Create
system.configandsystem.runtimefrom the resolved_config_object, add defaults, and validate.load_config_rc([conf_path])Load config from an rc-formatted file.
load_rc([config_path, default_config])Phase 1: Resolve the rc file path and load it into
system._config_object.merge_file_config(files)Phase 2: Extract
_configrows from the case file and merge them intosystem._config_object.save_config([file_path, overwrite])Save all system, model, and routine configurations to an rc-formatted file.
set_config([config])Set configuration for the System object.
update_config_object()Deprecated since version 2.0.