Simple Configuration. Just a table.
| Name | Type | Default | Description | Example |
|---|---|---|---|---|
PYDANTIC_SETTINGS_EXPORT__DEFAULT_SETTINGS |
array |
[] |
The default settings to use. The settings are applied in the order they are listed. | ["settings:settings"], ["app.config.settings:Settings","app.config.settings.dev:Settings"] |
PYDANTIC_SETTINGS_EXPORT__ROOT_DIR |
Path |
"<project_dir>" |
The project directory. Used for relative paths in the configuration file and .env file. If not set, will be the same as project_dir. | "<project_dir>" |
PYDANTIC_SETTINGS_EXPORT__PROJECT_DIR |
Path |
"<project_dir>" |
The project directory. Used for importing settings. | "<project_dir>" |
PYDANTIC_SETTINGS_EXPORT__RESPECT_EXCLUDE |
boolean |
true |
Respect the exclude attribute in the fields. | true |
PYDANTIC_SETTINGS_EXPORT__ENV_FILE |
Path | null |
null |
The path to the .env file to load environment variables. Useful when you have a Settings class/instance, which requires values while running. | null |
PYDANTIC_SETTINGS_EXPORT__RELATIVE_TO__REPLACE_ABS_PATHS |
boolean |
true |
Replace absolute paths with relative path to project root. | true |
PYDANTIC_SETTINGS_EXPORT__RELATIVE_TO__ALIAS |
string |
"<project_dir>" |
The alias for the relative directory. | "<project_dir>" |