rl-institut / oemof-B3

An open-source energy system model for Brandenburg/Berlin.
https://oemof-b3.readthedocs.io/
GNU Affero General Public License v3.0
9 stars 5 forks source link

FutureWarning in rule snakemake -j1 results/_resources/plots/scal_conv_pp-capacity_net_el.png #347

Closed Stefanie08 closed 1 year ago

Stefanie08 commented 1 year ago

Executing the rules

snakemake -j1 results/_resources/plots/scal_conv_pp-capacity_net_el.png

or

snakemake -j1 plot_all_resources

raises a FutureWarning concerning pandas. The pandas version used for this warning message is 3.0.2. The error message states teh following:

~\oemof-B3\oemof_b3\tools\data_processing.py:487: FutureWarning: The provided callable <built-in function sum> is currently using SeriesGroupBy.sum. In a future version of pandas, the provided callable will be used directly. To keep current behavior pass 'sum' instead. 
return df.groupby(groupby, sort=False, dropna=False).agg(agg_method)

This should be adapted to avoid any future errors.

MaGering commented 1 year ago

Thanks for finding this! Let's try to fix this within Milestone v0.0.3.

MaGering commented 1 year ago

Running snakemake -j1 results/_resources/plots/scal_conv_pp-capacity_net_el.png and snakemake -j1 plot_all_resources locally on branch features/update_tabular I could not reproduce the FutureWarning. Could you please check again if you get it @Stefanie08 and otherwise close this issue?

I'll change the Milestone to a later release date.

Thank You!

Stefanie08 commented 1 year ago

Thank you @MaGering for checking the issue. I opened a new environment and tried to reproduce the FutureWarning. The warning does not get printed anymore. Therefore, this issue will be closed.