upgrade sonic to v1.15.0 for go1.26 build - #37
Draft
isabst wants to merge 1 commit into
Draft
Conversation
vahnxu
added a commit
to vahnxu/kiro2api
that referenced
this pull request
Apr 17, 2026
Go 1.26.x build fails with sonic v1.14.1 due to missing GoMapIterator type. Upgrading to v1.15.0 restores build compatibility on modern Go toolchains. Same fix as PR caidaoli#37 (isabst). Verified with go 1.26.1 darwin/arm64 and linux/amd64.
3 tasks
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.
Summary
This change upgrades
github.com/bytedance/sonicfromv1.14.1tov1.15.0to restore build compatibility with Go1.26.x. It also updates the indirect dependencygithub.com/bytedance/sonic/loaderfromv0.3.0tov0.5.0as part of the module upgrade.Problem
Building the project with Go
1.26.1failed with:undefined: GoMapIteratoringithub.com/bytedance/sonic/internal/rt/stubs.go.This prevented producing the
kiro2apibinary on modern Go toolchains.Root Cause
sonic v1.14.1includes Go-runtime compatibility code with build tags that do not cover Go1.26, so the expectedGoMapIteratortype is not compiled for this toolchain. The project currently depends on that incompatible version.Fix
Upgrade to
sonic v1.15.0, which includes newer runtime compatibility updates for recent Go versions. No application code changes were required; only dependency metadata (go.mod/go.sum) changed.Validation
After the upgrade, the project builds successfully with:
go build -o kiro2api main.goon macOS arm64 with Go
1.26.1.