Skip to content
New issue

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

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

Already on GitHub? # to your account

Is it possible to use a nested group without automatically prefixing? #91

Open
onlywei opened this issue Dec 5, 2024 · 0 comments
Open

Comments

@onlywei
Copy link

onlywei commented Dec 5, 2024

I want to do this:

@environ.config
class MyGroup:
  my_special_value1 = environ.var()
  my_special_value2 = environ.var()

@environ.config(prefix="")
class AppSettings:
  group = environ.group(MyGroup)

But I want my environment variables to be:

MY_SPECIAL_VALUE1=55
MY_SPECIAL_VALUE2=88

I don't want:

GROUP_MY_SPECIAL_VALUE1=55
GROUP_MY_SPECIAL_VALUE2=88

Is there an option I can pass to the environ.group() function to achieve this?

# for free to join this conversation on GitHub. Already have an account? # to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant