Skip to content

Upgrade github actions agents to latest#363

Merged
ezralanglois merged 37 commits into
masterfrom
upgrade-windows-agent
Jun 14, 2025
Merged

Upgrade github actions agents to latest#363
ezralanglois merged 37 commits into
masterfrom
upgrade-windows-agent

Conversation

@ezralanglois

@ezralanglois ezralanglois commented Jun 10, 2025

Copy link
Copy Markdown
Member

Fix the deprecated windows-2019 agent issue
actions/runner-images#12045

Move all agents to latest to prevent future issues.


- name: Configure Windows
if: matrix.os == 'windows-latest'
if: ${{ startsWith(matrix.os, 'windows') }}

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

If we change the name from 2019 to latest, then this will prevent bugs

- uses: actions/checkout@v3
with:
fetch-depth: 0
- uses: actions/setup-dotnet@v4

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Fix crash when using the wrong dotnet core

Comment thread tools/package.bat
rem https://github.com/actions/setup-python/issues/121
echo %PREFIX_BEG% Configure %SUFFIX%
cmake %SOURCE_DIR% -G%COMPILER% -B%BUILD_DIR% %BUILD_PARAM%
cmake %SOURCE_DIR% -G%COMPILER% -B%BUILD_DIR% %BUILD_PARAM% -A x64

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Fix crash when trying to accidentally build 32-bit version

@ezralanglois ezralanglois marked this pull request as ready for review June 10, 2025 23:33
Comment thread .github/workflows/python.yml Outdated

- name: Package Python 3.8 and earlier
if: matrix.os == 'ubuntu-latest' && matrix.pyver != '3.9' && matrix.pyver != '3.10' && matrix.pyver != '3.11' && matrix.pyver != '3.12' && matrix.pyver != '3.13'
if: ${{ startsWith(matrix.os, 'ubuntu') && matrix.pyver != '3.9' && matrix.pyver != '3.10' && matrix.pyver != '3.11' && matrix.pyver != '3.12' && matrix.pyver != '3.13' }}

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

why does matrix.pyver <= '3.8' not work here?

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Because it is a string

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

sorry i meant are we explicitly checking that the version is anything below 3.9, meaning, we dont know what version it will be? or can we just do matrix.pyver == '3.8'

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

That is fair

Comment thread .github/workflows/python.yml Outdated
run: |
python -m pip install --upgrade pip setuptools wheel numpy
tools\package.bat Release "Visual Studio 16 2019" package_wheel "-DENABLE_APPS=OFF -DENABLE_EXAMPLES=OFF -DENABLE_CSHARP=OFF -DPython_EXECUTABLE=${{ steps.cpver.outputs.python-path }}" -DENABLE_PORTABLE=ON -A x64
tools\package.bat Release "Visual Studio 17 2022" package_wheel "-DENABLE_APPS=OFF -DENABLE_EXAMPLES=OFF -DENABLE_CSHARP=OFF -DPython_EXECUTABLE=${{ steps.cpver.outputs.python-path }}" -DENABLE_PORTABLE=ON -A x64

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

2022 is guaranteed to exist on the newest windows agents?

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We have to set this explicitly as far as I can tell

@ezralanglois ezralanglois merged commit 36601f4 into master Jun 14, 2025
35 checks passed
@ezralanglois ezralanglois deleted the upgrade-windows-agent branch June 14, 2025 18:05
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants