chore: bump sandbox opencode to 1.18.19 (message-ID rollover fix) - #14130
Merged
Conversation
wenxi-onyx
temporarily deployed
to
ci-protected
August 20, 2026 20:45 — with
GitHub Actions
Inactive
Contributor
Greptile SummaryUpdates the Craft sandbox image from opencode 1.18.13 to 1.18.19 to incorporate the upstream message-ID rollover fix.
Confidence Score: 5/5The PR appears safe to merge, with the runtime version pin and its documentation updated consistently. The narrowly scoped dependency pin addresses the described upstream rollover defect, and the reviewed changes reveal no concrete build, runtime, security, or documentation failure. Important Files Changed
Reviews (1): Last reviewed commit: "chore(craft): bump sandbox opencode to 1..." | Re-trigger Greptile |
wenxi-onyx
temporarily deployed
to
ci-protected
August 20, 2026 20:50 — with
GitHub Actions
Inactive
Contributor
🖼️ Visual Regression Report
|
wenxi-onyx
enabled auto-merge
August 20, 2026 21:22
Danelegend
approved these changes
Aug 20, 2026
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.
Description
opencode encodes message IDs with a 48-bit timestamp prefix that wrapped on 2026-08-14 11:19:55 UTC. In opencode <= 1.18.14, the prompt loop picks the "latest" message by lexicographic ID comparison, so any session with pre-wrap history silently ignores new prompts: the user message persists, the loop logs
step=0->exiting loop, and no assistant message is generated. We saw this live on managed_services tenant_dev (session995a7fb3), whose sandbox pins 1.18.13.Upstream fixed this in 1.18.15 (anomalyco/opencode#40990: order messages by
time.created, gate loop exit onparentID). This bumps the sandbox image pin to 1.18.19, the latest release. Wedged sessions recover on their own once their sandbox re-provisions with the new image; the message data in sqlite is intact.Also updates the matching snippet in
docs/craft/sandbox/image-and-spinup.md.How Has This Been Tested?
Root cause verified on the live tenant_dev sandbox: stored ID hex prefixes match the wrap math exactly (
msg_ff7de04af001pre-wrap vsmsg_0207f26e7001post-wrap), and v1.18.15+ no longer contains the vulnerablelastUser.id < lastAssistant.idexit check. Sandbox image build with the new pin is exercised by CI.Additional Options
Summary by cubic
Bumps sandbox
opencodeto 1.18.19 to fix the message-ID rollover that caused the prompt loop to exit early. Previously (<=1.18.14) sessions with pre-wrap history ignored new prompts and produced no assistant reply; 1.18.15+ orders messages by creation time and gates loop exit on parentID.OPENCODE_VERSION=1.18.19in the sandbox Dockerfile and mirror the version in docs.Written for commit 8f5a1f8. Summary will update on new commits.