fastoad.io.configuration.exceptions module

Exceptions for package configuration

exception fastoad.io.configuration.exceptions.FASTConfigurationBaseKeyBuildingError(original_exception: Exception, key: str, value=None)[source]

Bases: fastoad.exceptions.FastError

Class for being raised from bottom to top of TOML dict so that in the end, the message provides the full qualified name of the problematic key.

using new_err = FASTConfigurationBaseKeyBuildingError(err, ‘new_err_key’, <value>):

  • if err is a FASTConfigurationBaseKeyBuildingError instance with err.key==’err_key’:
    • new_err.key will be ‘new_err_key.err_key’

    • new_err.value will be err.value (no need to provide a value here)

    • new_err.original_exception will be err.original_exception

  • otherwise, new_err.key will be ‘new_err_key’ and new_err.value will be <value>
    • new_err.key will be ‘new_err_key’

    • new_err.value will be <value>

    • new_err.original_exception will be err

Parameters
  • original_exception – the error that happened for raising this one

  • key – the current key

  • value – the current value

Constructor

key

the “qualified key” (like “problem.group.component1”) related to error, build through raising up the error

value

the value related to error

original_exception

the original error, when eval failed

exception fastoad.io.configuration.exceptions.FASTConfigurationBadOpenMDAOInstructionError(original_exception: Exception, key: str, value=None)[source]

Bases: fastoad.io.configuration.exceptions.FASTConfigurationBaseKeyBuildingError

Class for managing errors that result from trying to set an attribute by eval.

Constructor

exception fastoad.io.configuration.exceptions.FASTConfigurationNanInInputFile(input_file_path: str, nan_variable_names: List[str])[source]

Bases: fastoad.exceptions.FastError

Raised if NaN values are read in input data file.