Skip to content

other: resolve latest compiler version from Obedients nightly build - #632

Merged
rebel-thkim merged 3 commits into
devfrom
ci/auto-compiler-update-via-obedients
Jul 16, 2026
Merged

other: resolve latest compiler version from Obedients nightly build#632
rebel-thkim merged 3 commits into
devfrom
ci/auto-compiler-update-via-obedients

Conversation

@rebel-thkim

@rebel-thkim rebel-thkim commented Jul 15, 2026

Copy link
Copy Markdown
Contributor

Problem

The auto compiler update workflow (auto_compiler_update_impl.yaml) picked the "latest" prod compiler version by PEP 440-sorting the package registry's version strings via parsing_latest_version.py.

rebel-compiler uses setuptools_scm-style versions where the .devN segment is the commit distance from the last tag. That count resets across branches, so a chronologically newer build can have a smaller N. Concretely:

build commit date version
side branch 8b9056e9 2026-07-07 0.11.1.dev501+g8b9056e9.prod
dev HEAD (nightly #441) 6beed8a0 2026-07-14 0.11.1.dev351+g6beed8a0.prod

Because dev351 < dev501 under PEP 440, the workflow pinned dev to the older side-branch build and would never advance to the real latest dev build (e.g. run 29361990709 skipped create-pr).

Fix

Resolve the version from the latest passed nightly build on dev in Obedients, reading VERSION_PROD from its compiler-nightly-version artifact:

  1. GET /pipelines/nightly/builds?branch=dev&state=passed&per_page=1 -> latest build (newest-first)
  2. find the compiler-nightly-version artifact of that build
  3. parse VERSION_PROD from it (download URL is pre-signed)

This tracks the actual dev HEAD, and branch=dev&state=passed filters out side-branch prod uploads. Both versions are now logged so a skipped create-pr is explainable from the run output.

Follows the Obedients API pattern from #630.

Required before merge

  • OBEDIENTS_API_TOKEN secret (already added)
  • OBEDIENTS_API_URL secret (Obedients API origin)

Notes

  • parsing_latest_version.py and DEV_PKG_URL are left in place -- still used by bc_latest_tag.yaml and rbln_optimum_pytest.yaml respectively.
  • jq/curl response shape handled defensively with (.items // .).

🤖 Generated with Claude Code

rebel-thkim and others added 3 commits July 15, 2026 18:23
The auto compiler update workflow picked the "latest" prod version by
PEP 440-sorting the package registry's version strings. rebel-compiler's
`.devN` segment is the commit distance from the last tag, which resets
across branches, so a chronologically newer build can have a smaller N
(e.g. dev branch build 0.11.1.dev351 < a side-branch 0.11.1.dev501).
Sorting then pins optimum-rbln to a stale side-branch build and never
advances to the real latest dev build.

Resolve the version from the latest passed `nightly` build on `dev`
instead, reading VERSION_PROD from its `compiler-nightly-version`
artifact. This tracks the actual dev HEAD and filters out side-branch
prod uploads via branch=dev&state=passed. Also log both versions so a
skipped create-pr is explainable from the run output.

Requires new repo secrets: OBEDIENTS_API_TOKEN, OBEDIENTS_API_URL.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
The dev/passed build list also contains nightly-build-AArch64 (ARM) and
nixl-triggered builds; the latter carry no compiler-nightly-version
artifact. Taking the newest build of any flavor could pick a build with
no manifest (breaking the run) or the ARM variant. Filter by
message=="nightly-build" to select the canonical amd64 prod nightly, and
fail loudly if the build, artifact, or VERSION_PROD is missing.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
`(.items // .)` errors on a bare-array response because indexing an
array with a string key is a hard error in jq, not null, so `//` never
catches it. Use an explicit type check so the step works whether the
Obedients API returns a bare array or an {items:[...]} envelope.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
@rebel-thkim
rebel-thkim requested a review from rebel-jongho July 15, 2026 09:34
@rebel-jongho rebel-jongho changed the title ci: resolve latest compiler version from Obedients nightly build other: resolve latest compiler version from Obedients nightly build Jul 15, 2026
@rebel-thkim
rebel-thkim merged commit c265782 into dev Jul 16, 2026
14 of 27 checks passed
@rebel-thkim
rebel-thkim deleted the ci/auto-compiler-update-via-obedients branch July 16, 2026 02:29
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