Skip to content

Commit 95bb054

Browse files
Mortara  AlessandroMortara  Alessandro
authored andcommitted
fix: update temporary solution input loading in Conductor
Updated the instruction that manages the odd behaviour while loading input files (value set to 1 are converted in True) in method __init__. To avoid that other values are converted unexpectedly, the explicit check for value == True is added in this commit. For instance this allows to avoid the conversion of variable INDUCTANCE_MODE = 2 into INDUCTANCE_MODE = 1 (because 2 is equivalent to true but is different from it). Class: Conductor modified: conductor.py
1 parent 59d7c9e commit 95bb054

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

source_code/conductor.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -184,7 +184,7 @@ def __init__(self: Self, simulation: object, sheetConductorsList: list, ICOND: i
184184
"INDUCTANCE_MODE",
185185
"ELECTRIC_SOLVER",
186186
]
187-
self.operations.update({key: 1 for key in keys if self.operations[key]})
187+
self.operations.update({key: 1 for key in keys if self.operations[key]==True})
188188
self.operations.update(
189189
{key: 0 for key in keys if self.operations[key] == False}
190190
)

0 commit comments

Comments
 (0)