From 31d2b2df8b4aeea4ccdfd98f455b9456048272e1 Mon Sep 17 00:00:00 2001 From: jean-pierre charras Date: Fri, 23 Jul 2021 11:28:02 +0200 Subject: [PATCH] QA test: fix a wx assert about Locale when running qa_python tests. Probably happens only when the system locale uses a comma as fp separator. --- pcbnew/python/scripting/pcbnew_scripting_helpers.cpp | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/pcbnew/python/scripting/pcbnew_scripting_helpers.cpp b/pcbnew/python/scripting/pcbnew_scripting_helpers.cpp index 13c1181a79..26a7adcd67 100644 --- a/pcbnew/python/scripting/pcbnew_scripting_helpers.cpp +++ b/pcbnew/python/scripting/pcbnew_scripting_helpers.cpp @@ -98,6 +98,10 @@ SETTINGS_MANAGER* GetSettingsManager() PROJECT* GetDefaultProject() { + // For some reasons, LoadProject() needs a C locale, so ensure we have the right locale + // This is mainly when running QA Python tests + LOCALE_IO dummy; + PROJECT* project = GetSettingsManager()->GetProject( "" ); if( !project )