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

refactor(get_env_vars): use get_env_vars() for consistent env variable retrieval #171

Merged
merged 1 commit into from
Dec 5, 2023

Conversation

ananta
Copy link
Contributor

@ananta ananta commented Dec 2, 2023

Refactor Environment Variable Retrieval Across Application - Resolves #168

Overview

This PR addresses issue #168 by refactoring the application to consistently use the get_env_vars() function for environment variable retrieval.

Proposed Changes

  • Added a new module in config.py, introducing the following components:
    • EnvVars: A class that encapsulates all environment variables required in the script.
    • get_env_vars(): A function to retrieve an instance of EnvVars populated with environment variables.

Readiness Checklist

Author/Contributor

  • run make lint and fix any issues that you have introduced
  • run make test and ensure you have test coverage for the lines you are introducing

Reviewer

  • Label as either bug, documentation, enhancement, infrastructure, or breaking

@ananta ananta requested a review from zkoppert as a code owner December 2, 2023 20:31
config.py Show resolved Hide resolved
Copy link
Member

@zkoppert zkoppert left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for contributing @ananta! This is a great improvement and it looks like everything from code to tests is well handled. Thank you! 🎉

@zkoppert zkoppert merged commit d80e1c0 into github:main Dec 5, 2023
5 checks passed
@parkerbxyz parkerbxyz mentioned this pull request Dec 20, 2023
4 tasks
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Not all env variables are being checked via the get_env_vars() function
2 participants