iota2.configuration_files.sections.cfg_utils
Definition of classes for configuration parameters
Functions
|
Add dunder methods based on the fields defined in the class. |
Classes
|
Special type indicating an unconstrained type. |
https://field-idempotency--pydantic-docs.netlify.app/usage/types/#custom-data-types |
|
|
|
|
Iota2 parameter section base class. |
|
PurePath subclass that can make system calls. |
https://field-idempotency--pydantic-docs.netlify.app/usage/types/#custom-data-types |
|
Definition of colors for terminal output |
Exceptions
|
Throws exceptions related to i2 config file. |
Print warnings. |
|
|
Print warnings. |
- exception iota2.configuration_files.sections.cfg_utils.ConfigError(msg, blinking=False)[source]
Throws exceptions related to i2 config file.
- exception iota2.configuration_files.sections.cfg_utils.ConfigNotRecognisedParamWarning(msg)[source]
Print warnings.
- exception iota2.configuration_files.sections.cfg_utils.ConfigParamWarning(msg)[source]
Print warnings.
- class iota2.configuration_files.sections.cfg_utils.FileParameter[source]
https://field-idempotency–pydantic-docs.netlify.app/usage/types/#custom-data-types
- class iota2.configuration_files.sections.cfg_utils.Iota2ParamSection(*args, **kwargs)[source]
Iota2 parameter section base class.
It ensures: - unrecognized fields (print a warning) - deactivate non-mandatory parameters (regarding builders)
- classmethod add_fields(**field_definitions)[source]
Add fields to an existing BaseModel.
Tribute to https://github.com/samuelcolvin/pydantic/issues/1937 :rtype:
NoneNote
If the field already exists, it will be overwritten
- deactivate_fields()
Deactivate non-mandatory parameters (regarding builders).
- unrecognized_fields()
Check if the user supplied parameter is known by iota2. If it is not, a warning is displayed.
- class iota2.configuration_files.sections.cfg_utils.PathParameter[source]
https://field-idempotency–pydantic-docs.netlify.app/usage/types/#custom-data-types
- class iota2.configuration_files.sections.cfg_utils.TermColors[source]
Definition of colors for terminal output
- BOLD = '\x1b[1m'
- ENDC = '\x1b[0m'
- FAIL = '\x1b[91m'
- HEADER = '\x1b[95m'
- OKBLUE = '\x1b[94m'
- OKCYAN = '\x1b[96m'
- OKGREEN = '\x1b[92m'
- UNDERLINE = '\x1b[4m'
- WARNING = '\x1b[93m'
- __init__()