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

Allow override of environment variables when calling load_dotenv #10

Open
rrodriguez44 opened this issue Jan 20, 2023 · 0 comments
Open

Comments

@rrodriguez44
Copy link

Environment

  • Doppler Env version: 0.3.1
  • Python version: 3.10
  • Operating System: Windows 10

Description

By default the doppler cli overrides environment variables found in system. You must pass --perserve-env flag to avoid the override. By default load_dotenv does not override environment variables so the behavior is reversed. I would think this would be consistent.

I am running into an issue where one of my variables setup in a doppler config is the same key name as one used by our end user computer team sets up on our workstations and I have no way of getting the up to date value from my doppler config.

Is it possible to have the same behavior as the cli and override by default by passing override=True to the load_dotenv call? And have the ability to control this behavior via environment variable?

Steps to Reproduce

  1. Have a system environment variable key name same as one in doppler config
  2. Up to date value will not be retrievable through os.getenv method when setting doppler_env=1

Expected Behavior

I expected to get the up to date value from doppler config, overriding the system environment variable of the same name

Screenshots

N/A

Additional Details

N/A

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

No branches or pull requests

1 participant