Skip to content

Bump go-sqlite3 to v1.14.53 to fix build warning - #142

Merged
tuhaihe merged 1 commit into
apache:mainfrom
tuhaihe:bump-go-sqlite3
Nov 10, 2026
Merged

tuhaihe merged 1 commit into
apache:mainfrom
tuhaihe:bump-go-sqlite3

Conversation

@tuhaihe

@tuhaihe tuhaihe commented Nov 9, 2026

Copy link
Copy Markdown
Member

The build on the ubuntu-26.04 runner prints this warning for each binary and test package that uses go-sqlite3:

  sqlite3-binding.c: In function 'sqlite3ShadowTableName':
  warning: assignment discards 'const' qualifier from pointer
  target type [-Wdiscarded-qualifiers]

go-sqlite3 v1.14.19 includes SQLite 3.44.0. In that SQLite version, sqlite3ShadowTableName() puts the result of strrchr() on a const string into a non-const pointer, and then writes through it. The new glibc on ubuntu-26.04 follows C23, so strrchr() on a const string returns a const pointer, and GCC reports the assignment.

SQLite fixed this function in 3.53.0, which go-sqlite3 includes from v1.14.44. Bump to the latest version, v1.14.53 (SQLite 3.54.1). It needs Go 1.21 or later, so the current Go 1.25 toolchain is fine.

See: #141

Assisted-by: Claude Code
Backpatch-through: REL_2_STABLE

closes: #ISSUE_Number


Change logs

Describe your change clearly, including what problem is being solved or what document is being added or updated.

Contributor's checklist

Here are some reminders before you submit your pull request:

The build on the ubuntu-26.04 runner prints this warning for each
binary and test package that uses go-sqlite3:

  sqlite3-binding.c: In function 'sqlite3ShadowTableName':
  warning: assignment discards 'const' qualifier from pointer
  target type [-Wdiscarded-qualifiers]

go-sqlite3 v1.14.19 includes SQLite 3.44.0. In that SQLite version,
sqlite3ShadowTableName() puts the result of strrchr() on a const
string into a non-const pointer, and then writes through it. The new
glibc on ubuntu-26.04 follows C23, so strrchr() on a const string
returns a const pointer, and GCC reports the assignment.

SQLite fixed this function in 3.53.0, which go-sqlite3 includes from
v1.14.44. Bump to the latest version, v1.14.53 (SQLite 3.54.1). It
needs Go 1.21 or later, so the current Go 1.25 toolchain is fine.

See: apache#141

Assisted-by: Claude Code
Backpatch-through: REL_2_STABLE
@tuhaihe
tuhaihe merged commit 3ef03a3 into apache:main Nov 10, 2026
20 checks passed
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