Skip to content

Commit

Permalink
fix bug in build_bus.py
Browse files Browse the repository at this point in the history
  • Loading branch information
panos-xenos committed Dec 18, 2024
1 parent 906b121 commit 6cfd2a7
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions pandapower/build_bus.py
Original file line number Diff line number Diff line change
Expand Up @@ -645,8 +645,7 @@ def _calc_shunts_and_add_on_ppc(net, ppc):
if np.any(vl & (s.step_dependency_table == True) & (pd.isna(s.id_characteristic_table))):
raise UserWarning("Shunts with step_dependency_table True and id_characteristic_table NA detected.\n"
"Please set an id_characteristic_table or set step_dependency_table to False.")
elif (np.any(vl & s.step_dependency_table == False
& ~pd.isna(s.id_characteristic_table))):
elif np.any(vl & (s.step_dependency_table == False) & (~pd.isna(s.id_characteristic_table))):
warnings.warn("Shunts with step_dependency_table False but id_characteristic_table detected.",
category=UserWarning)
s.step_dependency_table.fillna(False)
Expand Down

0 comments on commit 6cfd2a7

Please sign in to comment.