From 641b4b8f7bbc7ccdb2af8f01291de3703b88eafa Mon Sep 17 00:00:00 2001 From: Bjarke Madsen <bjarke@nordu.net> Date: Wed, 5 Feb 2025 10:15:33 +0100 Subject: [PATCH] Fix old_db_2022 survey publisher to not use enum value when saving external connections --- Changelog.md | 3 +++ compendium_v2/publishers/survey_publisher_old_db_2022.py | 4 ++-- 2 files changed, 5 insertions(+), 2 deletions(-) diff --git a/Changelog.md b/Changelog.md index 27d91653..aa1c6290 100644 --- a/Changelog.md +++ b/Changelog.md @@ -2,6 +2,9 @@ All notable changes to this project will be documented in this file. +## [0.86] - 2025-02-05 +- Fix old_db_2022 survey publisher to not use enum value when saving external connections + ## [0.85] - 2025-01-28 - Add back in old data publishers until the exported survey data is manually validated diff --git a/compendium_v2/publishers/survey_publisher_old_db_2022.py b/compendium_v2/publishers/survey_publisher_old_db_2022.py index f14cb467..c49d86ac 100644 --- a/compendium_v2/publishers/survey_publisher_old_db_2022.py +++ b/compendium_v2/publishers/survey_publisher_old_db_2022.py @@ -21,7 +21,7 @@ from collections import defaultdict import compendium_v2 from compendium_v2.conversion.mapping import CHARGING_LEVELS, CONNECTION, INTERCONNECTION, SERVICE_USER_TYPE_TO_CODE from compendium_v2.db.presentation_model_enums import CommercialCharges, CommercialConnectivityCoverage, \ - ConnectionMethod, FeeType, ServiceCategory, UserCategory, YesNoPlanned + FeeType, ServiceCategory, UserCategory, YesNoPlanned from compendium_v2.environment import setup_logging from compendium_v2.config import load from compendium_v2.publishers.helpers import extract_urls, valid_url @@ -1369,7 +1369,7 @@ def transfer_external_connections(nren_dict): conn_dict['capacity'] = None if conn_dict['interconnection_method']: int_conn = int_simple[conn_dict['interconnection_method'].replace(" ", "").lower()] - conn_dict['interconnection_method'] = ConnectionMethod[int_conn].value + conn_dict['interconnection_method'] = int_conn for nren_name, year in nren_year_set: if nren_name not in nren_dict: -- GitLab