Skip to content

Commit bb84724

Browse files
CodeCasterXclaudecodex
committed
fix(ci): build Homebrew bottles for arm64 only
- The Intel `macos-14-large` larger runner requires a paid plan and never provisions here (jobs end with 0 steps), making the "4 platforms green" gate unsatisfiable and blocking every release - Drop it from the bake matrix; the publish gate and the bottle-block generator now require the 3 arm64 platforms. Intel macOS installs build from source (`brew install` falls back automatically) - Update the gate count (3), EXPECTED_TAGS, and the workflow/generator tests Co-Authored-By: Claude <noreply@anthropic.com> Co-Authored-By: Codex <noreply@openai.com>
1 parent bd2d115 commit bb84724

4 files changed

Lines changed: 14 additions & 14 deletions

File tree

.github/scripts/generate-bottle-block.mjs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@ import { readFileSync, readdirSync, writeFileSync } from "node:fs";
22
import { join } from "node:path";
33
import { pathToFileURL } from "node:url";
44

5-
const EXPECTED_TAGS = ["arm64_tahoe", "arm64_sequoia", "arm64_sonoma", "sonoma"];
5+
const EXPECTED_TAGS = ["arm64_tahoe", "arm64_sequoia", "arm64_sonoma"];
66
const SYMBOL_CELLARS = new Set(["any", "any_skip_relocation"]);
77

88
export function generateBottleBlock(jsonObjects, { expectedTags = EXPECTED_TAGS } = {}) {

.github/workflows/update-homebrew.yml

Lines changed: 7 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -133,6 +133,9 @@ jobs:
133133
contents: write
134134
strategy:
135135
fail-fast: false
136+
# Apple Silicon (arm64) bottles only. The Intel `macos-14-large` larger
137+
# runner requires a paid plan and is unavailable here, so Intel macOS
138+
# users install via source build (`brew install` falls back automatically).
136139
matrix:
137140
include:
138141
- os: macos-26
@@ -141,8 +144,6 @@ jobs:
141144
platform: arm64_sequoia
142145
- os: macos-14
143146
platform: arm64_sonoma
144-
- os: macos-14-large
145-
platform: sonoma
146147
steps:
147148
- name: Configure brew tap
148149
run: brew tap fitlab-ai/tap
@@ -206,12 +207,12 @@ jobs:
206207
path: ./bottles
207208
merge-multiple: true
208209

209-
- name: Require all four bottles
210+
- name: Require all three bottles
210211
run: |
211212
COUNT=$(find ./bottles -name '*.bottle.json' | wc -l | tr -d ' ')
212-
echo "Found $COUNT bottle JSON files (expected 4)"
213-
if [ "$COUNT" -ne 4 ]; then
214-
echo "::error::Expected 4 bottle JSON files but found $COUNT"
213+
echo "Found $COUNT bottle JSON files (expected 3)"
214+
if [ "$COUNT" -ne 3 ]; then
215+
echo "::error::Expected 3 bottle JSON files but found $COUNT"
215216
exit 1
216217
fi
217218

tests/core/release.test.ts

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -88,13 +88,12 @@ test("update-homebrew workflow syncs the tap after a successful release run", ()
8888
assert.match(workflow, /os: macos-26[\s\S]*platform: arm64_tahoe/);
8989
assert.match(workflow, /os: macos-15[\s\S]*platform: arm64_sequoia/);
9090
assert.match(workflow, /os: macos-14[\s\S]*platform: arm64_sonoma/);
91-
assert.match(workflow, /os: macos-14-large[\s\S]*platform: sonoma/);
9291
assert.match(workflow, /brew install --build-bottle --formula --verbose agent-infra/);
9392
assert.match(workflow, /brew bottle --json --no-rebuild --root-url="\$ROOT_URL" agent-infra/);
9493
assert.match(workflow, /https:\/\/github\.com\/fitlab-ai\/agent-infra\/releases\/download\/v\$\{VERSION\}/);
9594
assert.match(workflow, /gh release upload "v\$\{VERSION\}"/);
9695
assert.match(workflow, /fail-fast: false/);
97-
assert.match(workflow, /Expected 4 bottle JSON files but found/);
96+
assert.match(workflow, /Expected 3 bottle JSON files but found/);
9897
assert.match(workflow, /publish-bottle:[\s\S]*needs: \[prepare-formula, bake-bottle\]/);
9998
assert.match(workflow, /generate-bottle-block\.mjs/);
10099
assert.match(workflow, /actions\/download-artifact@v7/);

tests/scripts/generate-bottle-block.test.ts

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ import { filePath } from "../helpers.ts";
99

1010
const scriptPath = filePath(".github/scripts/generate-bottle-block.mjs");
1111
const rootUrl = "https://github.com/fitlab-ai/agent-infra/releases/download/v0.6.2";
12-
const platforms = ["arm64_tahoe", "arm64_sequoia", "arm64_sonoma", "sonoma"];
12+
const platforms = ["arm64_tahoe", "arm64_sequoia", "arm64_sonoma"];
1313

1414
function bottleJson(platform: string, sha256: string, options: { rootUrl?: string; cellar?: string } = {}) {
1515
return {
@@ -95,18 +95,18 @@ test("generate-bottle-block replaces the formula placeholder when a formula path
9595
assert.equal(result.status, 0, result.stderr);
9696
assert.match(formula, / bottle do/);
9797
assert.match(formula, /root_url/);
98-
assert.match(formula, /sha256 cellar: :any_skip_relocation, sonoma:/);
98+
assert.match(formula, /sha256 cellar: :any_skip_relocation, arm64_sonoma:/);
9999
});
100100
});
101101

102102
test("generate-bottle-block fails when an expected platform is missing", () => {
103103
withTempDir((dir) => {
104-
writeBottles(dir, platforms.filter((platform) => platform !== "sonoma"));
104+
writeBottles(dir, platforms.filter((platform) => platform !== "arm64_sonoma"));
105105

106106
const result = runScript(["--bottles", dir]);
107107

108108
assert.notEqual(result.status, 0);
109-
assert.match(result.stderr, /missing bottle for platform: sonoma/);
109+
assert.match(result.stderr, /missing bottle for platform: arm64_sonoma/);
110110
});
111111
});
112112

@@ -117,7 +117,7 @@ test("generate-bottle-block fails when root URLs disagree", () => {
117117
path.join(dir, "agent-infra--0.6.2.arm64_sequoia.bottle.json"),
118118
JSON.stringify(bottleJson("arm64_sequoia", "2".repeat(64), { rootUrl: `${rootUrl}-other` }), null, 2),
119119
);
120-
writeBottles(dir, ["arm64_sonoma", "sonoma"]);
120+
writeBottles(dir, ["arm64_sonoma"]);
121121

122122
const result = runScript(["--bottles", dir]);
123123

0 commit comments

Comments
 (0)