Skip to content

Commit 575c3ab

Browse files
Fluf22cursoragent
andauthored
fix(ci): move macOS jobs off the retired macos-14 runner label (#7224)
Co-authored-by: Cursor Agent <cursoragent@cursor.com>
1 parent b4fd39c commit 575c3ab

3 files changed

Lines changed: 13 additions & 3 deletions

File tree

โ€Ž.github/workflows/check.ymlโ€Ž

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -341,7 +341,8 @@ jobs:
341341

342342
client_gen:
343343
timeout-minutes: 20 # swift CTS is excruciatingly slow
344-
runs-on: ${{ matrix.client.language == 'swift' && 'macos-14' || 'ubuntu-24.04' }}
344+
# swift runs on macOS with the version set in createMatrix.ts, not the minimum supported one
345+
runs-on: ${{ matrix.client.language == 'swift' && 'macos-15' || 'ubuntu-24.04' }}
345346
needs:
346347
- setup
347348
- specs
@@ -493,7 +494,7 @@ jobs:
493494
494495
kotlin_build_macos:
495496
timeout-minutes: 15
496-
runs-on: macos-14
497+
runs-on: macos-15
497498
needs:
498499
- setup
499500
- specs
@@ -540,6 +541,7 @@ jobs:
540541
id: setoutput
541542
run: echo "success=true" >> "$GITHUB_OUTPUT"
542543

544+
# builds with the minimum supported swift version (config/.swift-version), the macOS job in client_gen runs a newer one
543545
swift_build_linux:
544546
timeout-minutes: 10
545547
runs-on: ubuntu-22.04

โ€Žclients/algoliasearch-client-kotlin/.github/workflows/release.ymlโ€Ž

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ on:
88
jobs:
99
publish:
1010
name: Publish to Maven Central
11-
runs-on: macos-14
11+
runs-on: macos-15
1212
if: "startsWith(github.event.head_commit.message, 'chore: release')"
1313
steps:
1414
- name: Checkout

โ€Žscripts/ci/githubActions/createMatrix.tsโ€Ž

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,11 @@ import { COMMON_DEPENDENCIES, DEPENDENCIES, getVersionFileForLanguage, isBaseCha
1111
// This empty matrix is required by the CI, otherwise it throws
1212
const EMPTY_MATRIX = { client: ['no-run'] };
1313

14+
// The macOS runner only ships Xcode 16+: its SDK cannot be imported by swift < 6.0, and swift 6.0 cannot run the tests
15+
// against its XCTest, so we match the swift version bundled with Xcode 16.4.
16+
// This is only the CI toolchain, the minimum supported version stays in config/.swift-version and is checked on linux.
17+
const SWIFT_MACOS_CI_VERSION = '6.1';
18+
1419
async function createClientMatrix(baseBranch: string): Promise<void> {
1520
const matrix: Record<string, ToRunMatrix> = {};
1621
// PRs have origin/* as a baseBranch, main is always running from a specific commit
@@ -128,7 +133,10 @@ async function createClientMatrix(baseBranch: string): Promise<void> {
128133
// Swift requires the benchmark folder to have files in it
129134
languageMatrix.testsToDelete = `${testsOutputBase}/client ${testsOutputBase}/requests ${testsOutputBase}/e2e`;
130135
languageMatrix.testsToStore = `${languageMatrix.testsToStore} ${testsRootFolder}/Package.swift`;
136+
// the linux job reads SWIFT_DATA and builds with the minimum supported version
131137
setOutput('SWIFT_DATA', JSON.stringify(languageMatrix));
138+
// the matrix entry (macOS job) is the only one using the macOS toolchain
139+
languageMatrix.version = SWIFT_MACOS_CI_VERSION;
132140
break;
133141
default:
134142
break;

0 commit comments

Comments
ย (0)