2 ms·
That’s how I do it. .env files are terrible if you’re using them with a language specific loader. The entire point of env is that it’s an abstraction you can ma
by whalesalad 5y ago
That’s how I do it. .env files are terrible if you’re using them with a language specific loader. The entire point of env is that it’s an abstraction you can manipulate externally. You can setup the env, then launch the program. It allows for runtime changes.
https://whalesalad.com/blog/doing-python-configuration-right https://whalesalad.com/blog/doing-python-configuration-right
You can do it right without packages or external dependencies.
- pphysch 5y agoScrolling through the thread, this is my favorite so far. I like that it avoids counterproductive dependencies for loading a dotfile within the app. This is an operation that should be done at the same level as launches the Python interpreter, and Python should then complain if required envs are not set.