Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

use config.settings attributes instead of os.getenv #34

Merged
merged 1 commit into from
Nov 11, 2023
Merged

Conversation

VallariAg
Copy link
Member

@VallariAg VallariAg commented Nov 7, 2023

APISettings() will load all values from .env file as
APISettings's attributes. These can be imported in all
other modules, instead of using load_dotenv in every module.
ref: https://fastapi.tiangolo.com/advanced/settings/#reading-a-env-file

This also fixes the issue of missing value of PADDLES_URL in services/helpers.py

@VallariAg VallariAg added the bug Something isn't working label Nov 7, 2023
@VallariAg
Copy link
Member Author

@zmc using env_file: in docker-compose worked! thank you! :)

i have explained the problem that this issue solves in #38

APISettings() will load all values from .env file as
APISettings's attributes. These can be imported in all
other modules.
ref: https://fastapi.tiangolo.com/advanced/settings/#reading-a-env-file

This commit also fixes the issue of missing value of PADDLES_URL
in services/helpers.py

Signed-off-by: Vallari Agrawal <[email protected]>
@VallariAg VallariAg linked an issue Nov 8, 2023 that may be closed by this pull request
@zmc zmc merged commit 573fa93 into main Nov 11, 2023
3 checks passed
@zmc zmc deleted the fix-env-vars-usage branch November 11, 2023 00:16
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

Successfully merging this pull request may close these issues.

suite: t-api unable to reach paddles after scheduling
2 participants