From ac04abb98c1e021a0ce8aa74ed331f4156a7a8e3 Mon Sep 17 00:00:00 2001 From: "pre-commit-ci[bot]" <66853113+pre-commit-ci[bot]@users.noreply.github.com> Date: Wed, 9 Aug 2023 09:02:20 +0000 Subject: [PATCH 1/2] [pre-commit.ci] auto fixes from pre-commit.com hooks for more information, see https://pre-commit.ci --- scripts/prepare_sector_network.py | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/scripts/prepare_sector_network.py b/scripts/prepare_sector_network.py index 528eb32c..92d004f1 100644 --- a/scripts/prepare_sector_network.py +++ b/scripts/prepare_sector_network.py @@ -2883,7 +2883,9 @@ def add_industry(n, costs): p_set=p_set, ) - primary_steel = get(snakemake.config["industry"]["St_primary_fraction"], investment_year) + primary_steel = get( + snakemake.config["industry"]["St_primary_fraction"], investment_year + ) dri_steel = get(snakemake.config["industry"]["DRI_fraction"], investment_year) bof_steel = primary_steel - dri_steel From 41a35ad1290a78b458ed670f33f33ad2a29910a5 Mon Sep 17 00:00:00 2001 From: Fabian Neumann Date: Tue, 22 Aug 2023 11:53:02 +0200 Subject: [PATCH 2/2] bugfix: use of n.madd with singular value prevented --- scripts/prepare_sector_network.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/scripts/prepare_sector_network.py b/scripts/prepare_sector_network.py index 92d004f1..0e200925 100644 --- a/scripts/prepare_sector_network.py +++ b/scripts/prepare_sector_network.py @@ -2900,7 +2900,8 @@ def add_industry(n, costs): n.madd( "Load", - "coal for industry", + spatial.coal.nodes, + suffix=" for industry", bus=spatial.coal.nodes, carrier="coal for industry", p_set=p_set,