modex-flexmex / oemof-flexmex

oemof-flexmex is an oemof model built for model comparison within the Modex project FlexMex.
https://oemof-flexmex.readthedocs.io
MIT License
0 stars 0 forks source link

Logging problems: key error with system time #168

Open monika-o opened 3 years ago

monika-o commented 3 years ago

At some occasions, the postprocessing of FlexMex2_2 produces an error message which is related to the following two logging functions: log_solver_time_to_file(es.meta_results, exp_paths.logging_path) log_problem_metrics_to_file(es.meta_results, exp_paths.logging_path) The postprocessing works if these functions are commented out in oemof_flexmex/postprocessing.py.

monika-o commented 2 years ago

I got this error also when executing snakemake -j1 results/FlexMex2_1c/03_postprocessed --allowed-rules postprocess, so it is not only a problem in FlexMex2_2. And, to add to the above statement, the output in the snakefile obviously also needs to be adjusted for the postprocessing to run.

monika-o commented 2 years ago

Running snakemake -j1 results/FlexMex2_1a/03_postprocessed --allowed-rules postprocess results in the following error: Traceback (most recent call last): File "scripts/postprocessing.py", line 27, in <module> run_postprocessing(scenario_specs, paths) File "[...]/oemof-flexmex/oemof_flexmex/postprocessing.py", line 1229, in run_postprocessing log_solver_time_to_file(es.meta_results, exp_paths.logging_path) File "/[...]/oemof-flexmex/oemof_flexmex/postprocessing.py", line 1166, in log_solver_time_to_file "System time" KeyError: 'System time'