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
We are converting empty string to None type #146
Comments
Hi @Johk3r , my feeling is that an empty string should count as None in default as some assumptions must be taken and that's what most people will think of an empty string to count as, I'm open to having it be configurable with the default as is and in other cases the end user can define what values in
Can you please describe your usecase/why is this requested? |
HI @naorlivne, we use your library in our internal tool to interact with AWS cloud and terraform. Manage stack updates, etc.
|
Changing the current default won't work, while I see your use case there are others said change will break so we'll really be replacing one issue with another. I'm thinking something like having a configurable variable which by default is equal to
"empty" added will also be able to add their own.
This will require a bit more work though:
If you feel like making a PR to that affect I'll gladly merge it in. |
Sounds good, I'll try to get a PR with the change. |
Have the PR ready: #148 |
I think this is solved and can be closed. |
parse_it/parse_it/type_estimate/type_estimate.py
Line 25 in 3a87980
Is it possible to change this part in order to get empty string read as string and not converted to None type?
I've added a PR with this change applied globally, as another option it could also be optional configuration,
ex.:
ParseIt( empty_string_value="" | None )
The text was updated successfully, but these errors were encountered: