From e779dceae2408ee8b53a473232d0869470793364 Mon Sep 17 00:00:00 2001 From: monsieurswag Date: Wed, 4 Dec 2024 19:19:44 +0100 Subject: [PATCH 1/2] Make library store order deterministic --- backend/library/management/commands/storelibraries.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/backend/library/management/commands/storelibraries.py b/backend/library/management/commands/storelibraries.py index 617c74877..1cea6c96a 100644 --- a/backend/library/management/commands/storelibraries.py +++ b/backend/library/management/commands/storelibraries.py @@ -20,9 +20,9 @@ def handle(self, *args, **options): StoredLibrary.__init_class__() path = Path(options.get("path") or LIBRARIES_PATH) if path.is_dir(): - library_files = [ + library_files = sorted( f for f in path.iterdir() if f.is_file and f.suffix == ".yaml" - ] + ) else: library_files = [path] for fname in library_files: From 958db8465efb9814a637cb9f99a2797a3a58649e Mon Sep 17 00:00:00 2001 From: eric-intuitem <71850047+eric-intuitem@users.noreply.github.com> Date: Thu, 5 Dec 2024 01:04:30 +0100 Subject: [PATCH 2/2] Update RNSI-Algerie-2020.yaml Try make test pass removing carriage return in name --- backend/library/libraries/RNSI-Algerie-2020.yaml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/backend/library/libraries/RNSI-Algerie-2020.yaml b/backend/library/libraries/RNSI-Algerie-2020.yaml index 0dc2545a2..8a5e197ee 100644 --- a/backend/library/libraries/RNSI-Algerie-2020.yaml +++ b/backend/library/libraries/RNSI-Algerie-2020.yaml @@ -1,8 +1,8 @@ urn: urn:intuitem:risk:library:RNSI-ALGERIE-2020 locale: fr ref_id: RNSI-ALGERIE-2020 -name: "R\xE9f\xE9rentiel National\nde S\xE9curit\xE9 de l\u2019Information Alg\xE9\ - rie V2020 Par EKSEC.net" +name: "R\xE9f\xE9rentiel National de S\xE9curit\xE9 de l\u2019Information Alg\xE9\ + rie V2020 Par EKSEC.net" description: "\"EKSEC est fier de contribuer \xE0 la CISO Assistant Community et \xE0\ \ l\u2019Alg\xE9rie en int\xE9grant le R\xE9f\xE9rentiel National de S\xE9curit\xE9\ \ de l\u2019Information (RNSI) de l'Alg\xE9rie.\n\nLe R\xE9f\xE9rentiel National\