deprecate create_empty_network#2848
Conversation
refactored pandapowerNet and ADict to avoid circular imports replaced all calls to create_empty_network deprecated use of constructor for deepcopy name is now a required attribute for pandapowerNet
fixed reused names
…S-HTK/pandapower into feature/deprecate-create_empty_entwork
|
Why make a breaking change? |
The breaking part is that the constructor no longer allows a network without the default tables. net = pandapowerNet(name='')
for key in net:
del net[key]We discussed this and are of the opinion that if a object is a pandapowerNet it should at least contain the bus, line, trafo, etc. tables that were created by create_empty_network and it should not be possible to do What is not breaking is the use of create_empty_network. It was replaced with a function that calls pandapowerNet() and passes its parameters, and has also been marked as deprecated. |
Codecov Report❌ Patch coverage is Additional details and impacted files@@ Coverage Diff @@
## develop #2848 +/- ##
===========================================
- Coverage 72.26% 72.20% -0.07%
===========================================
Files 351 352 +1
Lines 37967 37941 -26
===========================================
- Hits 27438 27396 -42
- Misses 10529 10545 +16 ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
# Conflicts: # pandapower/auxiliary.py # pandapower/groups.py # pandapower/test/api/test_group.py # pandapower/test/conftest.py # pandapower/test/loadflow/test_facts_b2b_vsc.py # pandapower/test/loadflow/test_facts_vsc.py # pandapower/test/loadflow/test_rundcpp.py # pandapower/test/loadflow/test_runpp_3ph_n_line.py # pandapower/test/toolbox/test_result_info.py
added standard types dict type fixed all mypy issues
1dc8a6d to
c454d51
Compare
removed numpy1 warning test as the warning was removed
# Conflicts: # pandapower/shortcircuit/calc_sc.py # pandapower/test/api/test_create.py # pandapower/test/api/test_file_io.py # pandapower/test/contingency/test_contingency.py # pandapower/test/control/test_stactrl.py # pandapower/test/loadflow/result_test_network_generator.py # pandapower/test/loadflow/test_facts_b2b_vsc.py # pandapower/test/loadflow/test_facts_vsc.py # pandapower/test/loadflow/test_recycle.py # pandapower/test/loadflow/test_results.py # pandapower/test/loadflow/test_runpp.py # pandapower/test/loadflow/test_runpp_3ph.py # pandapower/test/loadflow/test_runpp_3ph_n_line.py # pandapower/test/loadflow/test_scenarios.py # pandapower/test/networks/test_kerber_networks.py # pandapower/test/opf/test_basic.py # pandapower/test/opf/test_check_opf_data.py # pandapower/test/opf/test_pandamodels_runpm.py # pandapower/test/toolbox/test_grid_modification.py
|
# Conflicts: # pandapower/diagnostic/diagnostic_functions.py # pandapower/estimation/algorithm/base.py # pandapower/estimation/algorithm/matrix_base.py # pandapower/groups.py # pandapower/plotting/collections.py # pandapower/test/api/test_auxiliary.py # pandapower/test/control/test_continuous_tap_control.py # pandapower/test/control/test_stactrl.py # pandapower/test/grid_equivalents/test_get_equivalent.py # pandapower/test/loadflow/test_runpp_3ph.py # pandapower/toolbox/data_modification.py # pandapower/toolbox/grid_modification.py
|



BREAKING CHANGES!
This pull request deprecates the create_empty_network functions and enables its functionality via the pandapowerNet constructor:
An additional attribute has been introduced
custom_datawhich allows for adding custom attributes to a pandapowerNet at creation.It is no longer possible to create a network without the default attributes.