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

feat: parse env var strings to expected config value types #3107

Merged

Conversation

mashb1t
Copy link
Collaborator

@mashb1t mashb1t commented Jun 6, 2024

enables config overrides of boolean values as they are potentially provided as strings by docker / docker compose

@mashb1t mashb1t changed the title fix: add try_parse_bool for env var strings fix: allow overrides of non-path values by env var Jun 6, 2024
@mashb1t mashb1t changed the title fix: allow overrides of non-path values by env var feat: parse env var strings to expected config value types Jun 6, 2024
@mashb1t mashb1t merged commit 5abae22 into lllyasviel:main Jun 6, 2024
csokun pushed a commit to csokun/Fooocus that referenced this pull request Jun 16, 2024
…l#3107)

* fix: add try_parse_bool for env var strings to enable config overrides of boolean values

* fix: fallback to given value if not parseable

* feat: extend eval to all valid types

* fix: remove return type

* fix: prevent strange type conversions by providing expected type

* feat: add tests
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant