Skip to content

Commit f638969

Browse files
authored
fix(release): fast self-contained idempotent pipeline + release runbook (#17)
* fix(release): fast self-contained idempotent pipeline + release runbook v0.11.0 was released from the web UI when the tag was pushed, so the workflow's unconditional gh release create failed on the collision and no assets were ever attached. Rework the pipeline around that failure mode and around wall-clock: - no marketplace actions: plain git checkout, pinned rustup install (bootstrapped on the rust-less macOS images), gh for all release IO - the reproducible-build gate runs as two parallel jobs per target instead of two serial builds in one job (~halves wall-clock; now also cross-runner instead of same-machine); windows-x64 stays single-build - release creation is a race-safe guard in each leg (notes from .github/release-notes.md); all uploads --clobber so re-runs converge - one publish job verifies the published assets against both build attempts, aggregates SHA256SUMS.txt, and runs the npm publish from the same download - DEVELOPMENT.md gains the release runbook * chore: release 0.11.2
1 parent 9684d94 commit f638969

8 files changed

Lines changed: 167 additions & 157 deletions

File tree

.github/release-notes.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
Reproducible builds: the linux and macOS binaries were each built from a clean tree in two independent CI jobs (separate runners) and required bit-identical before publishing; the windows binary is built once (mingw's linker has a residual link-order non-determinism). Toolchain: rust 1.97.0 (pinned), `--locked` against the committed Cargo.lock, `SOURCE_DATE_EPOCH` from the tagged commit. Each archive is self-contained: the `abgen` server binary plus the `template/` and `shader/` assets it needs, resolved from the binary's own directory (`ABGEN_ROOT`/`ABGEN_SHADER_BUNDLE` override). Runtime requirements - Linux (x64 and arm64): glibc >= 2.35 and libstdc++6/libgcc_s (present on any mainstream distro). Windows x64: none, the mingw runtime DLLs ship in the archive next to the exe. Windows arm64: none, a single static exe (llvm-mingw/libc++). macOS (Apple Silicon and Intel): system libraries only. Optional everywhere: libturbojpeg (bit-parity JPEG decode with the upstream ab-cdn pipeline; without it JPEG textures decode through a pure-Rust fallback - valid output, not guaranteed byte-identical to upstream bundles). The same binaries publish to npm as `@dcl/abgen` (per-platform packages as optionalDependencies; `npx @dcl/abgen` runs the server).

.github/workflows/release.yml

Lines changed: 136 additions & 151 deletions
Large diffs are not rendered by default.

Cargo.lock

Lines changed: 2 additions & 2 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

DEVELOPMENT.md

Lines changed: 24 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -180,3 +180,27 @@ AGPL-3.0-or-later (the Rust crate) - full text in [LICENSE](LICENSE). Vendored t
180180
Zlib, draco_decoder = MIT/Apache-2.0, libjpeg9c = IJG. Shader/template bundles are generated
181181
Decentraland content artifacts (sha256-pinned; regenerable via `scripts/bootstrap-runtime.sh`). Note:
182182
the lib sets `#[global_allocator] mimalloc`; any downstream embedding the lib inherits it.
183+
184+
## Releasing
185+
186+
The release pipeline (`.github/workflows/release.yml`) is plain shell on GitHub-hosted
187+
runners - no third-party or marketplace actions. Beyond the repo it trusts only rustup.rs
188+
(version-pinned toolchain) and the sha256-pinned llvm-mingw tarball. Every release
189+
operation is idempotent, so job re-runs converge on the full asset set.
190+
191+
1. Land a `chore: release X.Y.Z` PR bumping the crate version (Cargo.toml + Cargo.lock).
192+
2. Tag the merge commit and push the tag:
193+
`git tag vX.Y.Z <merge-sha> && git push origin vX.Y.Z`
194+
Don't pre-create the release in the web UI: the pipeline adopts an existing release
195+
(that is how v0.11.0 first shipped assetless), but only a CI-created one carries the
196+
notes from `.github/release-notes.md`.
197+
3. What runs: every target builds twice in parallel jobs on separate runners
198+
(windows-x64 once - mingw ld is non-deterministic); each leg packages, smoke-tests
199+
(`--version` + `/readyz`), and uploads its archive with `--clobber`. The `publish` job
200+
re-downloads the published assets, requires bit-identical hashes from both build
201+
attempts, verifies contents, uploads the aggregated `SHA256SUMS.txt`, and publishes
202+
npm (skipped explicitly when `NPM_TOKEN` is unset - why `@dcl/abgen` is not on npm).
203+
4. Verify: exactly 7 assets on the release page (6 archives + `SHA256SUMS.txt`).
204+
5. Failed leg: re-run failed jobs from the Actions UI; everything converges.
205+
206+
`workflow_dispatch` on a branch is a build+smoke dry run (no release, no uploads).

crate/Cargo.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
[package]
22
name = "abgen"
3-
version = "0.11.1"
3+
version = "0.11.2"
44
edition = "2021"
55
description = "Decentraland asset-bundle converter + ab-cdn-compatible JIT server — clean-room reimplementation of asset-bundle-converter."
66
license = "AGPL-3.0-or-later"

crate/dcl-contents/Cargo.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
[package]
22
name = "dcl-contents"
3-
version = "0.11.1"
3+
version = "0.11.2"
44
edition = "2021"
55
description = "Content-DB active-entity component, asset-bundle status DTOs, manifest-status reader, and the unsigned registry HTTP surface (profiles, entity status, world manifests)."
66

crate/kernel-ptx/Cargo.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
[package]
22
name = "abgen-gpu-kernel-ptx"
3-
version = "0.11.1"
3+
version = "0.11.2"
44
edition = "2021"
55
license = "AGPL-3.0-or-later"
66
description = "rustc-native nvptx64 PTX kernels for abgen-gpu-core (nightly + -Z build-std=core; artifact consumed by host via ABGEN_GPU_PTX)"

crate/wasm-poc/Cargo.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
[package]
22
name = "abgen-wasm-poc"
3-
version = "0.11.1"
3+
version = "0.11.2"
44
edition = "2021"
55
publish = false
66

0 commit comments

Comments
 (0)