fix(querylog): exclude sqlite on Solaris and illumos - #2242
Merged
Conversation
At the moment there is no pure-Go driver for SQLite available on illumos. For that reason disable it.
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## main #2242 +/- ##
==========================================
- Coverage 88.03% 87.99% -0.05%
==========================================
Files 126 126
Lines 9939 9939
==========================================
- Hits 8750 8746 -4
- Misses 924 927 +3
- Partials 265 266 +1 ☔ View full report in Codecov by Harness. 🚀 New features to boost your workflow:
|
53cfbda (0xERR0R#2123) excluded linux/loong64 from the SQLite query log because the pure-Go driver chain (modernc.org/sqlite -> modernc.org/libc) ships no generated code for it, but it only updated the two implementation files. database_writer_test.go imports github.com/glebarez/sqlite directly and carries its own copy of the constraint, which was left untouched. As a result the test binary still pulls in the driver and fails to compile: $ GOOS=linux GOARCH=loong64 go vet ./querylog/ package github.com/0xERR0R/blocky/querylog (test) imports github.com/glebarez/sqlite imports modernc.org/libc/errno: build constraints exclude all Go files Add the missing loong64 term so the three constraints stay in sync. Claude-Session: https://claude.ai/code/session_01X2Dg33aFoCW4AvWQasX5rX
The illumos exclusion added in the parent commit is correct but narrower than
it needs to be. modernc.org/sqlite ships no generated code for Solaris at all
(there is no capi_solaris_*.go / sqlite_solaris_*.go, and modernc.org/libc has
no solaris port either), so GOOS=solaris fails exactly like GOOS=illumos:
$ GOOS=solaris GOARCH=amd64 go build ./...
imports modernc.org/libc/errno: build constraints exclude all Go files
Go satisfies the solaris build tag for GOOS=illumos as well, so a single
solaris term covers both platforms. Widen the constraint instead of listing
illumos separately, and apply it to database_writer_test.go too, which imports
github.com/glebarez/sqlite directly and would otherwise still fail to compile
under go vet / go test on those platforms.
Verified per platform that exactly one of the two implementation files is
selected (real driver on linux/amd64, stub on illumos and solaris), that
build + vet are clean on illumos, solaris, linux/mips, linux/loong64 and every
current release target, and that go test ./querylog/ still passes natively.
Claude-Session: https://claude.ai/code/session_01X2Dg33aFoCW4AvWQasX5rX
Owner
|
Thanks! Reproduced the build failure and confirmed the fix — I pushed three follow-ups to your branch:
Verified |
The note listing where the sqlite target is unavailable was incomplete: it never picked up loong64 from 0xERR0R#2123, did not mention Solaris/illumos, and omitted the mips/mipsle variants of the BSD release targets. Restate it as the actual rule behind the build constraint and then give the affected official release builds. Verified against `go list` on every target in .goreleaser.yml that exactly these eleven select the stub, and that all remaining ones keep the real driver. Claude-Session: https://claude.ai/code/session_01X2Dg33aFoCW4AvWQasX5rX
0xERR0R
approved these changes
Sep 5, 2026
0xERR0R
enabled auto-merge (squash)
September 5, 2026 15:20
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.
At the moment there is no pure-Go driver for SQLite available on illumos. For that reason disable it.