Skip to content

sqlite: point at the 3.53.3 archive (now mirrored) - #511

Merged
twitchyliquid64 merged 2 commits into
mainfrom
fix-sqlite-stale-source-url
Jul 27, 2026
Merged

sqlite: point at the 3.53.3 archive (now mirrored)#511
twitchyliquid64 merged 2 commits into
mainfrom
fix-sqlite-stale-source-url

Conversation

@bryan-minimal

@bryan-minimal bryan-minimal commented Jul 22, 2026

Copy link
Copy Markdown
Member

Every build of sqlite has been failing:

HashMismatch want=c917d7db… got=a3db587a…

version and sha256 were bumped to 3.53.3 but the URL stayed on 3.50.4's archive — so the fetch pulled 3.50.4's bytes and checked them against 3.53.3's hash. A permanent failure, on the old toolchain and the new min/mip stack alike.

Verified by hashing both objects directly:

sha256
mirrored …-3500400.tar.gz a3db587a… ← the got=
upstream 3.53.3 tarball c917d7db… ← the pin, correct

What changed

The 3.53.3 archive was simply never mirrored. It is now — fetched from canonical upstream, sha256 verified against this pin both before and after upload — so this PR only moves the URL to the object that should always have been there. Source stays on gs:// per LICENSING.md §3 rather than redirecting upstream.

- url = "gs://minimal-staging-archives/sqlite-autoconf-3500400.tar.gz",
+ url = "gs://minimal-staging-archives/sqlite-autoconf-3530300.tar.gz",

Root cause worth naming

Nothing here derives from version. The zero-padded release number in the archive name (3.53.33530300) and the sha256 are independent copies. An updater that rewrites the sha but not the URL turns a routine bump into a silent break. Comment added at the site.

The general fix belongs in pkgmgr — it should refuse to rewrite a sha next to a version-bearing literal URL it cannot also update — and I'm filing that separately.

I checked the other 20 packages whose literal URL lacks their version: all legitimate (toolchain bootstrap seeds like glibc 2.43 building from a glibc_2.40 prebuilt, libkrunfw's bundled kernel, tamarin-prover's stackage snapshot). sqlite was the only real instance.

Found while getting package builds working on the new min/mip stack — a previous session read this as a credentials problem, but source fetches are hardcoded anonymous (mctx/src/lib.rs:605) and the bucket answers anonymously, so it was never auth.

🤖 Generated with Claude Code

Summary by CodeRabbit

  • Bug Fixes
    • Updated the SQLite build process to use the correct archive for version 3.53.3.
    • Prevented builds from extracting an outdated archive or switching to an incorrect directory.
    • Synchronized archive references to avoid checksum and build failures.

@coderabbitai

coderabbitai Bot commented Jul 22, 2026

Copy link
Copy Markdown
Contributor

Review Change Stack

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: Path: .coderabbit.yaml

Review profile: CHILL

Plan: Pro

Run ID: 06b0db8f-1d98-46a8-8dff-6f4f233e4da3

📥 Commits

Reviewing files that changed from the base of the PR and between 4a98d3a and 6d15832.

📒 Files selected for processing (2)
  • packages/sqlite/build.ncl
  • packages/sqlite/build.sh
🚧 Files skipped from review as they are similar to previous changes (2)
  • packages/sqlite/build.sh
  • packages/sqlite/build.ncl

📝 Walkthrough

Walkthrough

The SQLite build configuration and script now consistently reference the 3.53.3 autoconf archive, with comments documenting the mirrored archive naming and synchronization requirements.

Changes

SQLite mirrored archive update

Layer / File(s) Summary
SQLite archive URL and extraction synchronization
packages/sqlite/build.ncl, packages/sqlite/build.sh
The dependency URL and extraction command change from 3500400 to 3530300; comments document the archive suffix format and matching build directory.

Estimated code review effort: 1 (Trivial) | ~5 minutes

🚥 Pre-merge checks | ✅ 5
✅ Passed checks (5 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The title clearly summarizes the main change: SQLite now points to the mirrored 3.53.3 archive.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.
✨ Finishing Touches
📝 Generate docstrings
  • Create stacked PR
  • Commit on current branch
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch fix-sqlite-stale-source-url

Comment @coderabbitai help to get the list of available commands.

@coderabbitai coderabbitai Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 1

🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

Inline comments:
In `@LICENSING.md`:
- Around line 56-65: Update the retention policy wording in LICENSING.md so the
three-year retention period starts when the corresponding binary is first
publicly distributed and its written offer becomes available, not when the
archive is uploaded. State that retention must be extended for as long as the
binary remains distributed, while preserving the existing write-once,
mirror-migration, and verification requirements.
🪄 Autofix (Beta)

Fix all unresolved CodeRabbit comments on this PR:

  • Push a commit to this branch (recommended)
  • Create a new PR with the fixes

ℹ️ Review info
⚙️ Run configuration

Configuration used: Path: .coderabbit.yaml

Review profile: CHILL

Plan: Pro

Run ID: f8f65b0f-e35b-476c-b004-b350baf21339

📥 Commits

Reviewing files that changed from the base of the PR and between b043aad and caf07c4.

📒 Files selected for processing (2)
  • LICENSING.md
  • packages/sqlite/build.ncl

Comment thread LICENSING.md
Comment on lines +56 to +65
Mirror objects are write-once (uploads never overwrite) and the bucket
carries a three-year retention policy — the GPLv2 §3(b) written-offer
period — so archives cannot be deleted or modified while the offer is
live. Retention runs from each object's upload time and is reviewed
periodically, since the offer lasts for as long as the corresponding
binary is distributed. A weekly automated sweep verifies every distributed
copyleft package's exact pinned source is present on the mirror. If public
distribution moves to a different endpoint, these obligations follow
wherever consumers actually fetch, and the mirror and this policy move
with it.

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🗄️ Data Integrity & Integration | 🟠 Major | ⚡ Quick win

Do not start the GPLv2 retention clock at upload time.

An archive can be uploaded before its binary is first distributed; a three-year clock from upload could therefore expire before the written offer has been available for the required period. Anchor retention to the public distribution/offer date and extend it while the binary remains distributed.

Suggested wording
-Retention runs from each object's upload time and is reviewed
-periodically, since the offer lasts for as long as the corresponding
-binary is distributed.
+Retention is measured from the public distribution/offer date and is
+reviewed periodically; archives remain available for at least three
+years after that date and for as long as the corresponding binary is
+distributed.
📝 Committable suggestion

‼️ IMPORTANT
Carefully review the code before committing. Ensure that it accurately replaces the highlighted code, contains no missing lines, and has no issues with indentation. Thoroughly test & benchmark the code to ensure it meets the requirements.

Suggested change
Mirror objects are write-once (uploads never overwrite) and the bucket
carries a three-year retention policy — the GPLv2 §3(b) written-offer
period — so archives cannot be deleted or modified while the offer is
live. Retention runs from each object's upload time and is reviewed
periodically, since the offer lasts for as long as the corresponding
binary is distributed. A weekly automated sweep verifies every distributed
copyleft package's exact pinned source is present on the mirror. If public
distribution moves to a different endpoint, these obligations follow
wherever consumers actually fetch, and the mirror and this policy move
with it.
Mirror objects are write-once (uploads never overwrite) and the bucket
carries a three-year retention policy — the GPLv2 §3(b) written-offer
period — so archives cannot be deleted or modified while the offer is
live. Retention is measured from the public distribution/offer date and is
reviewed periodically; archives remain available for at least three
years after that date and for as long as the corresponding binary is
distributed. A weekly automated sweep verifies every distributed
copyleft package's exact pinned source is present on the mirror. If public
distribution moves to a different endpoint, these obligations follow
wherever consumers actually fetch, and the mirror and this policy move
with it.
🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In `@LICENSING.md` around lines 56 - 65, Update the retention policy wording in
LICENSING.md so the three-year retention period starts when the corresponding
binary is first publicly distributed and its written offer becomes available,
not when the archive is uploaded. State that retention must be extended for as
long as the binary remains distributed, while preserving the existing
write-once, mirror-migration, and verification requirements.

Source: MCP tools

@twitchyliquid64
twitchyliquid64 added this pull request to the merge queue Jul 24, 2026
@github-merge-queue
github-merge-queue Bot removed this pull request from the merge queue due to failed status checks Jul 24, 2026
bryan-minimal and others added 2 commits July 26, 2026 22:19
Every build of sqlite has been failing:

    HashMismatch want=c917d7db… got=a3db587a…

`version` and `sha256` were bumped to 3.53.3 but this URL stayed on
3.50.4's archive, so the fetch pulled 3.50.4's bytes and checked them
against 3.53.3's hash — a permanent failure, on the old toolchain and
the new min/mip stack alike. Verified by hashing both objects: the
mirrored 3500400 archive is a3db587a…, and c917d7db… is the correct
hash of upstream's 3.53.3 tarball.

The 3.53.3 archive was simply never mirrored. It is now — fetched from
canonical upstream, sha256 verified against this pin before and after
upload — so this only has to move to the object that should always have
been here. Source stays on gs:// per LICENSING.md §3 rather than
redirecting to upstream.

Root cause worth naming: nothing here derives from `version`. The
zero-padded release number in the archive name and the sha256 are
independent copies, so an updater that rewrites the sha but not the URL
turns a routine bump into a silent break. Comment added. The general fix
belongs in pkgmgr — it should refuse to rewrite a sha next to a
version-bearing literal URL it cannot also update — and is filed
separately.

Checked the other 20 packages whose literal URL lacks their version:
all legitimate (toolchain bootstrap SEEDS like glibc 2.43 building from
a glibc_2.40 prebuilt, libkrunfw's bundled kernel, tamarin-prover's
stackage snapshot). sqlite was the only real instance.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
The buildbot failed on the previous commit:

    tar: sqlite-autoconf-3500400.tar.gz: Cannot open: No such file or directory

build.sh was ALSO half-updated by the 3.53.3 bump — line 5 already said
`cd sqlite-autoconf-3530300` while line 4 still extracted
`sqlite-autoconf-3500400.tar.gz`. Before, that combination merely
never got the chance to fail: the fetch died on HashMismatch first.
Fixing the URL moved the failure one step later, to this.

The version is encoded in FIVE independent places across the package —
`version`, the archive name in the URL, the sha256, the `tar` argument
and the `cd` target — and the bump updated three. This is the last one.

`tar -xof` retained: the disallowed-patterns checker requires that exact
form.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
@twitchyliquid64
twitchyliquid64 force-pushed the fix-sqlite-stale-source-url branch from 5799586 to 6d15832 Compare July 27, 2026 05:19
@twitchyliquid64
twitchyliquid64 added this pull request to the merge queue Jul 27, 2026
Merged via the queue into main with commit dc9f81d Jul 27, 2026
10 checks passed
@twitchyliquid64
twitchyliquid64 deleted the fix-sqlite-stale-source-url branch July 27, 2026 08:17
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