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

Convert CLI provided strings to booleans for boolean config variables #2029

Conversation

tylermilner
Copy link
Contributor

Fixes #1973 - a bug where the override value provided via command line wasn't being properly converted to its boolean counterpart.

Since override values from the command line are interpreted as strings, we need to convert the override value to a boolean if it's overriding a boolean variable.

I'm a total Python newbie so please let me know if there's anything I can change to make this better.

tylermilner and others added 6 commits March 5, 2024 23:54
…cutter#1973)

Fixes a bug where the override value provided via command line wasn't being properly converted to its boolean counterpart.

Since override values from the command line are interpreted as strings, we need to convert the string value to a boolean if the config variable is a boolean to begin with.
@jensens jensens added the bug This issue/PR relates to a bug. label Mar 25, 2024
@jensens jensens changed the title fix: convert strings to booleans for boolean config variables (#1973) Convert CLI provided strings to booleans for boolean config variables Mar 25, 2024
@jensens jensens merged commit 7abf35f into cookiecutter:main Mar 25, 2024
24 checks passed
@jensens
Copy link
Contributor

jensens commented Mar 25, 2024

Thanks!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug This issue/PR relates to a bug.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Cannot properly override boolean variable from command line
2 participants