Hi, installing pandapipes in complex environments became more and more difficult, because all other packages I use have transitioned to pandas 3.* at this point. Only pandapipes/pandapower are still limited to pandas<3.0. For me using pandas 2 is causing "seemingly random" errors in unrelated packages.
It now took me less time to fix all the pandas 3 errors in pandapipes than what I had previously spent on manually restricting broken dependencies.
I published all the required changes here:
https://github.com/jnettels/pandapipes/tree/fix/pandas3
There are not even that many changes required, just a bunch of
res_table['deltat_k'].values[:] changing to
res_table.loc[:, 'deltat_k'].
However, e.g.
res_table[res_name].values[pt] had to be changed to
res_table.iloc[pt, res_table.columns.get_loc(res_name)]
and I must admit that I am not 100% sure iloc might be necessary instead of loc in some more places (where during my tests I could not tell if the indexer was the actual index or just the index number.)
Nevertheless, all tests are passing and my examples run fine.
Besides the actual code changes, I changed the pandapower dependency to a fork, too:
https://github.com/jnettels/pandapower/tree/fix/pandas3
(pandapower 3.3.3 did not show any conflicts with pandas 3, only the dependency in pyproject.toml had to be removed.)
I will gladly create a PR from my changes if that is useful. But as another PR of mine #776 seems to be ignored and there also seems to be some larger restructuring going on in #820 I am not sure about that.
Cheers and thanks for this project!
Hi, installing pandapipes in complex environments became more and more difficult, because all other packages I use have transitioned to pandas 3.* at this point. Only pandapipes/pandapower are still limited to pandas<3.0. For me using pandas 2 is causing "seemingly random" errors in unrelated packages.
It now took me less time to fix all the pandas 3 errors in pandapipes than what I had previously spent on manually restricting broken dependencies.
I published all the required changes here:
https://github.com/jnettels/pandapipes/tree/fix/pandas3
There are not even that many changes required, just a bunch of
res_table['deltat_k'].values[:]changing tores_table.loc[:, 'deltat_k'].However, e.g.
res_table[res_name].values[pt]had to be changed tores_table.iloc[pt, res_table.columns.get_loc(res_name)]and I must admit that I am not 100% sure
ilocmight be necessary instead oflocin some more places (where during my tests I could not tell if the indexer was the actual index or just the index number.)Nevertheless, all tests are passing and my examples run fine.
Besides the actual code changes, I changed the pandapower dependency to a fork, too:
https://github.com/jnettels/pandapower/tree/fix/pandas3
(pandapower 3.3.3 did not show any conflicts with pandas 3, only the dependency in pyproject.toml had to be removed.)
I will gladly create a PR from my changes if that is useful. But as another PR of mine #776 seems to be ignored and there also seems to be some larger restructuring going on in #820 I am not sure about that.
Cheers and thanks for this project!