lang_tools.params.lang_tools_params
¶
LangTools project params.
Parameters are actual value of the config.
The class is a singleton, so it can be accessed from anywhere in the code.
There is a parameter regarding the environment type (stage and location), which is used to load different paths and other parameters based on the environment.
Classes:
-
LangToolsParams–LangTools project parameters.
Functions:
-
get_lang_tools_params–Get the lang_tools params.
-
get_lang_tools_paths–Get the lang_tools paths.
-
get_webapp_params–Get the webapp params.
LangToolsParams
¶
LangTools project parameters.
Load the LangTools params.
Methods:
-
__repr__–Return the string representation of the object.
-
__str__–Return the string representation of the object.
-
load_config–Load the lang_tools configuration.
-
set_env_type–Set the environment type.
Source code in src/lang_tools/params/lang_tools_params.py
__repr__
¶
__str__
¶
Return the string representation of the object.
load_config
¶
Load the lang_tools configuration.
Source code in src/lang_tools/params/lang_tools_params.py
set_env_type
¶
Set the environment type.
Parameters:
-
env_type(EnvType | None, default:None) –The environment type. If None, it will be set from the environment variables. Defaults to None.