3535 # Allow manual invocation.
3636 workflow_dispatch :
3737
38- # Declare default permissions as read only.
38+ # Declare default workflow permissions as read only.
3939permissions : read-all
4040
4141jobs :
@@ -50,30 +50,27 @@ jobs:
5050 # These Python versions were carefully selected by trial and error
5151 # to be available on as many os/arch combos as possible, while also
5252 # making all necessary Python dependencies available on those combos.
53- # TODO: add '3.13.1' once Cirq 1.5 is released.
54- python-version : ['3.10.11', '3.11.9', '3.12.7']
55- os : [ubuntu-22.04, ubuntu-22.04-arm, macos-14, windows-2022]
53+ python-version : ['3.11.9', '3.12.7', '3.13.1']
54+ os : [ubuntu-24.04, ubuntu-24.04-arm, macos-15, macos-14, windows-2025]
5655 arch : [x64, arm64]
5756 exclude :
57+ - os : ubuntu-24.04
58+ arch : arm64
59+
60+ - os : ubuntu-24.04-arm
61+ arch : x64
62+
5863 # MacOS 14 is only available for arm64.
5964 - os : macos-14
6065 arch : x64
6166
62- # Windows is only available for x64.
63- - os : windows-2022
64- arch : arm64
65-
66- # GitHub provides separate Ubuntu runners for ARM and x64.
67- # We have to exclude the incompatible combinations.
68- - os : ubuntu-22.04-arm
67+ # MacOS 15 is only available for arm64.
68+ - os : macos-15
6969 arch : x64
70- - os : ubuntu-22.04
71- arch : arm64
7270
73- # 2025-01-31 dependency h5py fails to build on this combo (only) .
74- - os : ubuntu-22.04-arm
71+ # Windows 2025 is only available for x64 .
72+ - os : windows-2025
7573 arch : arm64
76- python-version : 3.12.7
7774
7875 steps :
7976 - name : Check out a copy of the OpenFermion git repository
@@ -89,19 +86,45 @@ jobs:
8986 cache-dependency-path : dev_tools/requirements/envs/pytest.env.txt
9087
9188 - name : Install OpenFermion Python requirements
92- run : |
93- pip install -r dev_tools/requirements/envs/pytest.env.txt
94- echo '::group::List of installed pip packages and their versions'
95- pip list
96- echo '::endgroup::'
89+ run : pip install -r dev_tools/requirements/envs/pytest.env.txt
9790
9891 - name : Install cirq-core (current stable version)
99- run : |
100- pip install -U cirq-core ${{inputs.args}}
92+ run : pip install -U cirq-core ${{inputs.args}}
10193
10294 - name : Set up Pytest output problem matcher
10395 run : echo '::add-matcher::.github/problem-matchers/pytest.json'
10496
10597 - name : Run Pytest
98+ run : check/pytest
99+
100+ - name : Print debugging info upon job failure
101+ if : failure()
102+ shell : bash
103+ env :
104+ GITHUB_CONTEXT : ${{toJson(github)}}
105+ RUNNER_CONTEXT : ${{toJson(runner)}}
106+ MATRIX_CONTEXT : ${{toJson(matrix)}}
107+ STRATEGY_CONTEXT : ${{toJson(strategy)}}
106108 run : |
107- check/pytest
109+ echo '::group:: Shell environment'
110+ env
111+ echo '::endgroup::'
112+ echo '::group:: Installed Python packages'
113+ pip list
114+ echo '::endgroup::'
115+ echo '::group:: GitHub context'
116+ echo "The job_id is: $GITHUB_JOB"
117+ echo "The id of this action is: $GITHUB_ACTION"
118+ echo "The run id is: $GITHUB_RUN_ID"
119+ echo "GitHub SHA: $GITHUB_SHA"
120+ echo "$GITHUB_CONTEXT"
121+ echo '::endgroup::'
122+ echo '::group:: GitHub runner context'
123+ echo "$RUNNER_CONTEXT"
124+ echo '::endgroup::'
125+ echo '::group:: Matrix context'
126+ echo "$MATRIX_CONTEXT"
127+ echo '::endgroup::'
128+ echo '::group:: Strategy context'
129+ echo "$STRATEGY_CONTEXT"
130+ echo '::endgroup::'
0 commit comments