From 0f35ec8287438c3cecd4bd3727839dff29af44ba Mon Sep 17 00:00:00 2001 From: Nickolay Olshevsky Date: Mon, 4 Nov 2024 13:58:52 +0200 Subject: [PATCH] Debug msys codepage failure. --- .github/workflows/windows-msys2.yml | 45 +++++++++++++++++++++++++++++ 1 file changed, 45 insertions(+) diff --git a/.github/workflows/windows-msys2.yml b/.github/workflows/windows-msys2.yml index 9377ee0f92..4415743137 100644 --- a/.github/workflows/windows-msys2.yml +++ b/.github/workflows/windows-msys2.yml @@ -94,6 +94,28 @@ jobs: fetch-depth: 1 submodules: true + - name: Check environment + run: | + chcp + echo %PATH% + echo Lang: + echo %LANG% + echo LC_ALL: + echo %LC_ALL% + echo chcp.com: + chcp 65001 + echo Printing unicode 1: + echo ✓ + echo Printing unicode 2: + echo Блабла + where python + where python3 + set PYTHONUTF8=1 + echo Printing from Python: + python -c "print('\u2713')" + python -c "import sys; print(sys.stdout.encoding)" + shell: cmd + - name: Install MSys uses: msys2/setup-msys2@v2 with: @@ -127,8 +149,31 @@ jobs: - name: Test run: | + # Change codepage to utf-8 + cat /d/a/_temp/setup-msys2/msys2.CMD + echo $PATH + echo "Lang:" + echo $LANG || true + echo "LC_ALL:" + echo $LC_ALL || true + echo "chcp.com:" + chcp.com 65001 || true + echo "Printing unicode 1:" + echo -e "\xE2\x9C\x93" + echo "Printing unicode 2:" + printf "Блабла" + which python || true + which python3 || true + export PYTHONUTF8=1 + echo "Printing from Python:" + python -c 'print("\u2713")' || true + python -c 'import sys; print(sys.stdout.encoding)' || true mkdir -p "build/Testing/Temporary" cp "cmake/CTestCostData.txt" "build/Testing/Temporary" + export LC_ALL="en_US.UTF-8" + export LANG="en_US.UTF-8" + export PYTHONIOENCODING=utf-8 + export PYTHONUTF8=1 export PATH="$PWD/build/src/lib:$PATH" export RNP_LOG_CONSOLE=1 ctest --parallel ${{ env.CORES }} --test-dir build -C Debug --output-on-failure