-
Notifications
You must be signed in to change notification settings - Fork 46
Open
Description
Hi,
I just want to report that the following code pass the if-statement although the transformer_data["isltc"] value is 0: https://github.com/NREL/ditto/blob/9a5cb71a6dd48f45b64e74a88b61140b129970e1/ditto/readers/cyme/read.py#L4777
This is because the transformer_data["isltc"] value type is the String, so "0" is always considered as true value in the if statement.
I could fix in my local version to handle this issue to change the line as follow:
if "isltc" in transformer_data and int(transformer_data["isltc"].strip()):
I hope this information is helpful for the repository
Metadata
Metadata
Assignees
Labels
No labels