Repository navigation
SQLite apps and amber database on Grant's own engine (2.0.19 candidate) - #82
Merged
Merged
Conversation
amber new -d sqlite now requires grant/adapter/sqlite/grant_engine, so the app links no C SQLite library; a comment in config/database.cr and the README name the one-line require that brings the C library back. amber database runs on the same engine, so the CLI links no libsqlite3. The generated-app linkage check now also fails on libsqlite3 or any sqlite3_ import. Re-applies #75 (c55b725) on main; version 2.0.19.
…te3 reads its migrated database as sound check_generated_app_linkage.sh now fails on any libsqlite3 library or sqlite3_ import in the default and scaffolded apps, and runs the C sqlite3 tool's PRAGMA integrity_check on the test database amber database migrate wrote through Grant's engine. CI installs the sqlite3 tool on Ubuntu; macOS has /usr/bin/sqlite3. The release workflow also rejects libsqlite3 in the CLI.
Grant 0.29.0 carries the engine's Windows support, the C-parity fixes (#145 #146 #150 #151 #153), C-shaped rollback journals (#156 #158), the one-descent delete (#165) and the 0.28.1/0.28.2 fixes merged forward. Generated apps and the CLI's own lock both pin it; the checksum is the one Minecart wrote for a fresh amber new -d sqlite, and a frozen reinstall verifies it.
…ned symbols, CLI linkage in PR CI - check_generated_app_linkage.sh: integrity_check fails with a message when the test database is missing or sqlite3 itself fails, and opens it read-only so the tool never creates an empty file; the sqlite3_ count uses plain nm, so a statically linked libsqlite3 is caught too. - build.yml: every build asserts the CLI links no libsqlite3 and holds no sqlite3_ symbol (otool on macOS, ldd on Linux). - new_command_spec: pg and mysql apps keep their own adapter require and carry no SQLite engine note. - ci.yml: the build-libraries comment matches what the CLI links.
…hat is not last never fails a bash -e step)
Member
Author
|
Independent review (separate agent, crystal-conventions rubric): first pass at 3ed0480 MAJOR 0 / MINOR 6; MINOR 1, 2, 3, 5 and 6 fixed in b159659 and 6d92e10; re-review of 3ed0480..6d92e10 MAJOR 0 / MINOR 0, mergeable. MINOR 4 (unused templates/app/config/database.cr.ecr) left for a follow-up. CI 13/13 green on 6d92e10. Gates on the candidate (Grant v0.29.0 pin):
The release (tag, archives, Homebrew tap) is held so 2.0.19 ships together with the Beryl OpenSSL opt-out removal (relay B3V). |
crimson-knight
marked this pull request as ready for review
November 28, 2026 04:28
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Makes Grant's own SQLite engine the default for
amber new -d sqlite(re-applies #75, c55b725, onto main), after the 72-hour engine soak passed (2026-11-28T01:30Z, 0 lost commits of 727,228).config/database.crrequiresgrant/adapter/sqlite/grant_engine; its comment and the README name the one-line switch back:require "grant/adapter/sqlite". Database files are the same either way.amber databaseruns on the same engine, so the CLI links no libsqlite3 (otool -L bin/amber: libSystem only, local build).scripts/check_generated_app_linkage.shnow also fails on libsqlite3 / anysqlite3_import, and runssqlite3 ... PRAGMA integrity_checkon the databaseamber database migratewrote.Release is held so this ships with the Beryl OpenSSL opt-out removal (B3V) as one Amber CLI release.
Local macOS gate on this head (Grant 0.28.2 pin): fresh app links libSystem only, 0 sqlite3_ imports, specs 1/0, scaffold specs 12/0, migrate development/test integrity_check ok, one-line switch to C builds with libsqlite3 and passes 12/0. amber_cli specs touched: 210 examples, 0 failures.