base_settings
A base class to store common logic needed from settings classes.
BaseSettings
dataclass
Bases: ABC
A base class to store common logic needed from settings classes.
Dataclasses like this help with type checking and setting defaults. They also make it really easy to add new settings.
Methods:
| Name | Description |
|---|---|
__post_init__ |
Optionally validates the input settings after the dataclass is initialized. |
validate |
Validates the input settings. |
__str__ |
Returns a string representation of the settings. |
__repr__ |
Returns a string representation of the settings. |
Source code in src/mada_tools/shared/base_settings.py
__post_init__()
__repr__()
__str__()
Returns a string representation of the settings.
Source code in src/mada_tools/shared/base_settings.py
validate()
Validates the input settings.
This method can be overridden by subclasses to provide specific validation logic.