You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
If the second network in passed to the merge_nets function has a DataFrame that is not present within the first network the merge_nets function fails. This is because the check to determin if a DataFrame needs to be reindexed takes all DataFrames from the second network (with some exceptions e.g. key starts with _ or res_) and tries to verify that no index of net2[key] is in net[key].index but if net[key] does not exist it crashes.
Expected Behavior
OPTIONAL: A warning that a user Created DataFrame was encountered and references within might not be updated correctly.
The DataFrame that is not present should be merged to the output network without issue as it does not have any overlap with the first network.
Installed Versions
python version: 3.12
pandas version: 2.2.1
networkx version: 3.2.1
scipy version: 1.12.0
numpy version: 1.26.4
packaging version: 24.0
tqdm version: 4.66.2
deepdiff version: 6.7.1
Operating System name/version: Windows 10 Enterprise 22H2
Label
Relevant labels are selected
The text was updated successfully, but these errors were encountered:
Bug report checklis
Searched the issues page for similar reports
Read the relevant sections of the documentation
Browse the tutorials and tests for usefull code snippets and examples of use
Reproduced the issue after updating with
pip install --upgrade pandapower
(orgit pull
)Tried basic troubleshooting (if a bug/error) like restarting the interpreter and checking the pythonpath
Reproducible Example
Issue Description and Traceback
If the second network in passed to the merge_nets function has a DataFrame that is not present within the first network the merge_nets function fails. This is because the check to determin if a DataFrame needs to be reindexed takes all DataFrames from the second network (with some exceptions e.g. key starts with _ or res_) and tries to verify that no index of net2[key] is in net[key].index but if net[key] does not exist it crashes.
Expected Behavior
OPTIONAL: A warning that a user Created DataFrame was encountered and references within might not be updated correctly.
The DataFrame that is not present should be merged to the output network without issue as it does not have any overlap with the first network.
Installed Versions
Label
The text was updated successfully, but these errors were encountered: