Repository navigation
Commit 3f864ec
fix: build release binaries against the live models.dev catalog
`.github/workflows/release.yml` built every platform binary with
`MODELS_DEV_API_JSON: test/tool/fixtures/models-api.json`, so each shipped
binary embedded a checked-in test fixture as its bundled models.dev catalog
instead of a release-time one. The fixture's newest entry is `2026-03-30`.
Verified against the shipped `0.9.7` binary in an isolated `HOME`: its
snapshot-only `openai` set is exactly the fixture's (46 of 47 ids, missing only
`gpt-5-chat-latest`, which is filtered elsewhere), with zero ids the fixture
does not have. That catalog still offers 11 ids the live catalog has dropped
(`gpt-5-codex`, `gpt-5.1-codex`, `gpt-5.1-codex-max`, `gpt-5.1-codex-mini`,
`gpt-5.2-codex`, `codex-mini-latest`, `o1-mini`, `o1-preview`, and three
others) and is missing `gpt-5.5` plus every `gpt-5.6` variant. It carries 105
providers against the live catalog's 207, so the staleness is not
OpenAI-specific.
Upstream's `publish.yml` sets no such override and fetches live at release
time; `git log -S` shows ours has been there since the initial fork commit
`f2cd5c1245` with no explanatory comment, and reads as copy-paste from the CI
job where a hermetic build genuinely is correct.
Removing the override makes release builds depend on models.dev, so
`build.ts` now validates the payload before writing the snapshot:
- non-2xx responses throw instead of flowing an error page into the snapshot
(`fetch` resolves for 4xx/5xx, and a JSON error body is valid TypeScript
that would have shipped as a catalog with no providers)
- the payload must parse, be a provider object, carry at least 50 providers,
and include `anthropic`, `openai` and `google`
`ci.yml` and `pre-release-check.ts` keep the fixture pin — a hermetic build is
correct there.
Co-Authored-By: Claude Opus 5 <[email protected]>
Claude-Session: https://claude.ai/code/session_01VqnuBDGkh1ZT65Ti7e6DHZ1 parent c59a5a2 commit 3f864ec
2 files changed
Lines changed: 56 additions & 3 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
98 | 98 | | |
99 | 99 | | |
100 | 100 | | |
101 | | - | |
| 101 | + | |
| 102 | + | |
| 103 | + | |
| 104 | + | |
| 105 | + | |
| 106 | + | |
102 | 107 | | |
103 | 108 | | |
104 | 109 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
28 | 28 | | |
29 | 29 | | |
30 | 30 | | |
31 | | - | |
| 31 | + | |
| 32 | + | |
| 33 | + | |
| 34 | + | |
| 35 | + | |
| 36 | + | |
| 37 | + | |
| 38 | + | |
| 39 | + | |
| 40 | + | |
| 41 | + | |
| 42 | + | |
| 43 | + | |
| 44 | + | |
| 45 | + | |
| 46 | + | |
| 47 | + | |
| 48 | + | |
| 49 | + | |
| 50 | + | |
| 51 | + | |
| 52 | + | |
| 53 | + | |
| 54 | + | |
| 55 | + | |
| 56 | + | |
| 57 | + | |
| 58 | + | |
| 59 | + | |
| 60 | + | |
| 61 | + | |
| 62 | + | |
| 63 | + | |
| 64 | + | |
| 65 | + | |
| 66 | + | |
| 67 | + | |
| 68 | + | |
| 69 | + | |
| 70 | + | |
| 71 | + | |
| 72 | + | |
| 73 | + | |
| 74 | + | |
| 75 | + | |
| 76 | + | |
| 77 | + | |
| 78 | + | |
32 | 79 | | |
33 | 80 | | |
34 | | - | |
| 81 | + | |
| 82 | + | |
35 | 83 | | |
36 | 84 | | |
37 | 85 | | |
| |||
0 commit comments