Skip to content

Commit bcb6d63

Browse files
authored
fix msys ci python issue (#3651)
* msys ci: un-pin setup-msys2 action version * msys ci: explicitly set PYTHONHOME and PYTHONPATH for c++ and interface tests (to workaround msys2/setup-msys2#167)
1 parent dedda22 commit bcb6d63

File tree

1 file changed

+7
-8
lines changed

1 file changed

+7
-8
lines changed

.github/workflows/ci.yml

Lines changed: 7 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -904,8 +904,7 @@ jobs:
904904
- { sys: mingw64, env: x86_64 }
905905
- { sys: mingw32, env: i686 }
906906
steps:
907-
# Force version because of https://github.com/msys2/setup-msys2/issues/167
908-
- uses: msys2/[email protected]
907+
- uses: msys2/setup-msys2@v2
909908
with:
910909
msystem: ${{matrix.sys}}
911910
install: >-
@@ -935,10 +934,10 @@ jobs:
935934
run: cmake --build build --target pytest -j 2
936935

937936
- name: C++11 tests
938-
run: cmake --build build --target cpptest -j 2
937+
run: PYTHONHOME=/${{matrix.sys}} PYTHONPATH=/${{matrix.sys}} cmake --build build --target cpptest -j 2
939938

940939
- name: Interface test C++11
941-
run: cmake --build build --target test_cmake_build
940+
run: PYTHONHOME=/${{matrix.sys}} PYTHONPATH=/${{matrix.sys}} cmake --build build --target test_cmake_build
942941

943942
- name: Clean directory
944943
run: git clean -fdx
@@ -953,10 +952,10 @@ jobs:
953952
run: cmake --build build2 --target pytest -j 2
954953

955954
- name: C++14 tests
956-
run: cmake --build build2 --target cpptest -j 2
955+
run: PYTHONHOME=/${{matrix.sys}} PYTHONPATH=/${{matrix.sys}} cmake --build build2 --target cpptest -j 2
957956

958957
- name: Interface test C++14
959-
run: cmake --build build2 --target test_cmake_build
958+
run: PYTHONHOME=/${{matrix.sys}} PYTHONPATH=/${{matrix.sys}} cmake --build build2 --target test_cmake_build
960959

961960
- name: Clean directory
962961
run: git clean -fdx
@@ -971,7 +970,7 @@ jobs:
971970
run: cmake --build build3 --target pytest -j 2
972971

973972
- name: C++17 tests
974-
run: cmake --build build3 --target cpptest -j 2
973+
run: PYTHONHOME=/${{matrix.sys}} PYTHONPATH=/${{matrix.sys}} cmake --build build3 --target cpptest -j 2
975974

976975
- name: Interface test C++17
977-
run: cmake --build build3 --target test_cmake_build
976+
run: PYTHONHOME=/${{matrix.sys}} PYTHONPATH=/${{matrix.sys}} cmake --build build3 --target test_cmake_build

0 commit comments

Comments
 (0)