Convert CLI provided strings to booleans for boolean config variables#2029
Merged
jensens merged 6 commits intocookiecutter:mainfrom Mar 25, 2024
Merged
Conversation
…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
approved these changes
Mar 25, 2024
Contributor
|
Thanks! |
|
Would love a release with this fix. Just noticed our CI is not actually testing what I thought it was because of this issue |
Contributor
|
You are right, it is time for a release. I'll put it on my todo list for the next days! Thanks for the reminder! |
|
@jensens thanks! Was able to work around it with a pre-generate hook, so no rush 😉 |
|
Looks like 2.6.0 was in February, this to me seems like a fix release? What's the hold up here? |
9 tasks
|
This would be a nice feature to have in a release version of |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
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.