Skip to content

fix(ci): make release workflow build reliably (drop cache that prunes libduckdb) - #210

Merged
jrosskopf merged 2 commits into
mainfrom
fix/release-libduckdb-relink
Jun 27, 2026
Merged

fix(ci): make release workflow build reliably (drop cache that prunes libduckdb)#210
jrosskopf merged 2 commits into
mainfrom
fix/release-libduckdb-relink

Conversation

@jrosskopf

@jrosskopf jrosskopf commented Jun 27, 2026

Copy link
Copy Markdown
Contributor

Summary

Follow-up to the new release.yml (#208). The workflow_dispatch dry-run surfaced two issues on the non-Linux legs, both now fixed and validated green on all three platforms:

  1. Windows boot — fixed by the .gitattributes eol=lf change (fix: .gitattributes eol=lf — unblock Windows release build (CRLF-mangled embedded assets) #209): Windows checkout CRLF-mangled an embedded markdown asset, so escurel-server failed boot-time validation.
  2. unable to find library -lduckdb (this PR) — on any run with a restored cache, the link failed: rust-cache prunes the downloaded shared libduckdb from target/duckdb-download when it saves, so a restored cache has the -L search path set but the lib gone. cargo clean -p libduckdb-sys didn't help ("Removed 0 files"). The first cache-less run linked fine everywhere, so the cache was the sole culprit.

Fix: drop rust-cache from the release matrix. Release builds run on tag pushes only, so a clean from-scratch build per platform is the right trade for guaranteed-correct linking. The frequent Linux gate in ci.yml keeps its cache.

Validation

Dispatched release.yml on this branch (run 28294056243) — all three build jobs succeeded: cold build → libduckdb bundling + rpath fix → smoke test (boots escurel-server, hits /healthz, proving libduckdb loads) → package. create-release correctly skipped (no tag).

Test plan

  • Linux gate (this PR).
  • After merge: cut v1.0.1-rc.1 to exercise the full publish (create-release → GitHub pre-release with the three platform archives).

🤖 Generated with Claude Code


View with Codesmith Autofix with Codesmith
Need help on this PR? Tag /codesmith with what you need. Autofix is disabled.

jrosskopf and others added 2 commits June 27, 2026 17:42
…ilure)

The release dry-run's second run failed at the build step with
`rust-lld: error: unable to find library -lduckdb` on all platforms — the
classic warm-cache/cold-link-path problem: a restored rust-cache keeps the
libduckdb-sys build-script fingerprint warm, so cargo skips the script and
never re-emits `cargo:rustc-link-search`, and the final link can't find
libduckdb even though the .so/.dll is in the cached download dir.

The previous conditional "ensure present" check was insufficient (the lib is
present yet the link path is unset). Unconditionally `cargo clean -p
libduckdb-sys` so the script always re-runs; it reuses the cached
target/duckdb-download, so this is a cheap re-link, not a re-download.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
…d libduckdb)

The relink-forcing attempt didn't help: `cargo clean -p libduckdb-sys`
reported "Removed 0 files", yet the link still failed with `unable to find
library -lduckdb` — the search path pointed at target/duckdb-download but the
.so wasn't there. rust-cache prunes the downloaded shared libduckdb when it
saves the cache, so any restored cache link-fails.

The very first (cache-less) dry-run linked fine on all three platforms, so the
cache was the only thing breaking it. Release builds run on tag pushes only,
so just drop rust-cache here and build clean from scratch — slower per run but
guaranteed-correct linking. ci.yml (the frequent gate) keeps its cache.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
@jrosskopf
jrosskopf merged commit fb62aa4 into main Jun 27, 2026
5 checks passed
@jrosskopf
jrosskopf deleted the fix/release-libduckdb-relink branch June 27, 2026 16:28
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.

1 participant