From 45a6057506c393f96f85921ac6ffac2029e08949 Mon Sep 17 00:00:00 2001 From: Andrew Eisenberg Date: Mon, 4 Nov 2024 12:39:23 -0800 Subject: [PATCH 1/3] Move to macos-13 runners Macos-12 runners are deprecated and are refusing to run. --- .github/workflows/__go-tracing-autobuilder.yml | 2 +- .github/workflows/__go-tracing-custom-build-steps.yml | 2 +- .github/workflows/__go-tracing-legacy-workflow.yml | 2 +- .github/workflows/__multi-language-autodetect.yml | 2 +- pr-checks/sync.py | 2 +- 5 files changed, 5 insertions(+), 5 deletions(-) diff --git a/.github/workflows/__go-tracing-autobuilder.yml b/.github/workflows/__go-tracing-autobuilder.yml index 252490356b..d4a84fc6d8 100644 --- a/.github/workflows/__go-tracing-autobuilder.yml +++ b/.github/workflows/__go-tracing-autobuilder.yml @@ -29,7 +29,7 @@ jobs: include: - os: ubuntu-latest version: stable-v2.14.6 - - os: macos-12 + - os: macos-13 version: stable-v2.14.6 - os: ubuntu-latest version: stable-v2.15.5 diff --git a/.github/workflows/__go-tracing-custom-build-steps.yml b/.github/workflows/__go-tracing-custom-build-steps.yml index 2ba4314296..52b769bd49 100644 --- a/.github/workflows/__go-tracing-custom-build-steps.yml +++ b/.github/workflows/__go-tracing-custom-build-steps.yml @@ -29,7 +29,7 @@ jobs: include: - os: ubuntu-latest version: stable-v2.14.6 - - os: macos-12 + - os: macos-13 version: stable-v2.14.6 - os: ubuntu-latest version: stable-v2.15.5 diff --git a/.github/workflows/__go-tracing-legacy-workflow.yml b/.github/workflows/__go-tracing-legacy-workflow.yml index c4707c1b7b..46f8b85c5d 100644 --- a/.github/workflows/__go-tracing-legacy-workflow.yml +++ b/.github/workflows/__go-tracing-legacy-workflow.yml @@ -29,7 +29,7 @@ jobs: include: - os: ubuntu-latest version: stable-v2.14.6 - - os: macos-12 + - os: macos-13 version: stable-v2.14.6 - os: ubuntu-latest version: stable-v2.15.5 diff --git a/.github/workflows/__multi-language-autodetect.yml b/.github/workflows/__multi-language-autodetect.yml index f7df487ac2..9e8a3c273e 100644 --- a/.github/workflows/__multi-language-autodetect.yml +++ b/.github/workflows/__multi-language-autodetect.yml @@ -27,7 +27,7 @@ jobs: fail-fast: false matrix: include: - - os: macos-12 + - os: macos-13 version: stable-v2.14.6 - os: ubuntu-latest version: stable-v2.14.6 diff --git a/pr-checks/sync.py b/pr-checks/sync.py index 37b120b439..32250070ec 100755 --- a/pr-checks/sync.py +++ b/pr-checks/sync.py @@ -84,7 +84,7 @@ def writeHeader(checkStream): # "macos-latest" is now an ARM runner, so we run tests on the old CLIs on Intel runners instead. if version in ["stable-v2.14.6"] and runnerImage == "macos-latest": matrix.append({ - 'os': "macos-12", + 'os': "macos-13", 'version': version }) else: From 34919cb664cc748cbf7e9fe69f7b03902880bf29 Mon Sep 17 00:00:00 2001 From: Andrew Eisenberg Date: Mon, 4 Nov 2024 13:57:39 -0800 Subject: [PATCH 2/3] Update codeql.yml workflow --- .github/workflows/codeql.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/codeql.yml b/.github/workflows/codeql.yml index ef6275ff00..0703ff3676 100644 --- a/.github/workflows/codeql.yml +++ b/.github/workflows/codeql.yml @@ -75,7 +75,7 @@ jobs: strategy: fail-fast: false matrix: - os: [ubuntu-20.04,ubuntu-22.04,windows-2019,windows-2022,macos-12,macos-13,macos-14] + os: [ubuntu-20.04,ubuntu-22.04,windows-2019,windows-2022,macos-13,macos-14] tools: ${{ fromJson(needs.check-codeql-versions.outputs.versions) }} runs-on: ${{ matrix.os }} From 1489c9c99239dac1f9b5f8a4ddd44ee5a800ff68 Mon Sep 17 00:00:00 2001 From: Andrew Eisenberg Date: Wed, 6 Nov 2024 15:23:10 -0800 Subject: [PATCH 3/3] Exclude Swift on macos for version 2.14.6 --- .github/workflows/__multi-language-autodetect.yml | 13 ++++++++----- pr-checks/checks/multi-language-autodetect.yml | 10 ++++++---- tests/multi-language-repo/build.sh | 2 ++ 3 files changed, 16 insertions(+), 9 deletions(-) diff --git a/.github/workflows/__multi-language-autodetect.yml b/.github/workflows/__multi-language-autodetect.yml index 9e8a3c273e..7f1346d137 100644 --- a/.github/workflows/__multi-language-autodetect.yml +++ b/.github/workflows/__multi-language-autodetect.yml @@ -88,13 +88,15 @@ jobs: id: init with: db-location: ${{ runner.temp }}/customDbLocation - # Swift is not supported on Ubuntu so we manually exclude it from the list here - languages: ${{ runner.os == 'Linux' && 'cpp,csharp,go,java,javascript,python,ruby' - || '' }} + # Swift is not supported on Ubuntu or codeql 2.14 so we manually exclude it from the list here + languages: ${{ (runner.os == 'Linux' || (runner.os == 'macOS' && matrix.version + == 'stable-v2.14.6')) && 'cpp,csharp,go,java,javascript,python,ruby' || + '' }} tools: ${{ steps.prepare-test.outputs.tools-url }} - uses: ./../action/.github/actions/setup-swift - if: runner.os == 'macOS' + # Exclude macos on v2.14.6 since we can not longer run swift on ARM runners + if: runner.os == 'macOS' && matrix.version != 'stable-v2.14.6' with: codeql-path: ${{ steps.init.outputs.codeql-path }} @@ -147,7 +149,8 @@ jobs: fi - name: Check language autodetect for Swift on macOS - if: runner.os == 'macOS' + # Exclude macos on v2.14.6 since we can not longer run swift on ARM runners + if: runner.os == 'macOS' && matrix.version != 'stable-v2.14.6' shell: bash run: | SWIFT_DB=${{ fromJson(steps.analysis.outputs.db-locations).swift }} diff --git a/pr-checks/checks/multi-language-autodetect.yml b/pr-checks/checks/multi-language-autodetect.yml index 0990961bbc..1bb2ad4258 100644 --- a/pr-checks/checks/multi-language-autodetect.yml +++ b/pr-checks/checks/multi-language-autodetect.yml @@ -10,12 +10,13 @@ steps: id: init with: db-location: "${{ runner.temp }}/customDbLocation" - # Swift is not supported on Ubuntu so we manually exclude it from the list here - languages: ${{ runner.os == 'Linux' && 'cpp,csharp,go,java,javascript,python,ruby' || '' }} + # Swift is not supported on Ubuntu or codeql 2.14 so we manually exclude it from the list here + languages: ${{ (runner.os == 'Linux' || (runner.os == 'macOS' && matrix.version == 'stable-v2.14.6')) && 'cpp,csharp,go,java,javascript,python,ruby' || '' }} tools: ${{ steps.prepare-test.outputs.tools-url }} - uses: ./../action/.github/actions/setup-swift - if: runner.os == 'macOS' + # Exclude macos on v2.14.6 since we can not longer run swift on ARM runners + if: runner.os == 'macOS' && matrix.version != 'stable-v2.14.6' with: codeql-path: ${{ steps.init.outputs.codeql-path }} @@ -68,7 +69,8 @@ steps: fi - name: Check language autodetect for Swift on macOS - if: runner.os == 'macOS' + # Exclude macos on v2.14.6 since we can not longer run swift on ARM runners + if: runner.os == 'macOS' && matrix.version != 'stable-v2.14.6' shell: bash run: | SWIFT_DB=${{ fromJson(steps.analysis.outputs.db-locations).swift }} diff --git a/tests/multi-language-repo/build.sh b/tests/multi-language-repo/build.sh index 84d8096144..3ebb97fb0c 100755 --- a/tests/multi-language-repo/build.sh +++ b/tests/multi-language-repo/build.sh @@ -8,7 +8,9 @@ javac Main.java go build main.go +# Not all platforms support Swift if [[ "$OSTYPE" == "darwin"* ]]; then + echo "Compiling Swift" swift build fi