Skip to content

fix: backport 9 upstream bug fixes (B1-B9)#16

Merged
e6qu merged 8 commits intodevfrom
fix/upstream-backports
Mar 18, 2026
Merged

fix: backport 9 upstream bug fixes (B1-B9)#16
e6qu merged 8 commits intodevfrom
fix/upstream-backports

Conversation

@e6qu
Copy link
Owner

@e6qu e6qu commented Mar 17, 2026

Summary

Backports 9 bug fixes from upstream anomalyco/opencode, one commit per original author. These are independent of the Effect service refactor and can be merged safely.

Fix Author Upstream PR
B1: detect context_length_exceeded error code Johannes Loher anomalyco/opencode#17748
B2: apply message transforms during compaction DS anomalyco/opencode#17823
B3: forward session permission ruleset to LLM stream Jason Quense anomalyco/opencode#17064
B4: add prompt schema validation debug logs Kit Langton anomalyco/opencode#17812
B5: log ZodError issues on schema validation failure Adrian Mârza — (no upstream PR)
B6: wrap question option descriptions instead of truncating Shoubhit Dash anomalyco/opencode#17782
B7: check for selected text in dialog escape handler Kyle Altendorf anomalyco/opencode#16779
B8/B9: fix inverted HEAD filter in VCS watcher Kit Langton / Aiden Cline anomalyco/opencode#17829, #17673

Test plan

  • bun typecheck passes
  • bun test — all 1401 tests pass
  • Manual: verify branch switch detection works in TUI
  • Manual: verify dialog escape with text selection
  • Manual: verify question option text wraps instead of truncating

kitlangton and others added 8 commits March 18, 2026 02:01
The file watcher was ignoring HEAD changes instead of filtering
non-HEAD changes, so branch switches were never detected.

Upstream: anomalyco/opencode#17829 (e5cbecf)
Co-authored-by: Aiden Cline <63023139+rekram1-node@users.noreply.github.com>
…t B1 #17748)

Parse response body for error code so providers returning
context_length_exceeded are correctly classified as context overflow.

Upstream: anomalyco/opencode#17748 (e718db6)
… B5)

Print the specific validation issues alongside the stack trace to make
debugging schema mismatches easier.
…B7 #16779)

Check getSelectedText() instead of just getSelection() so escape
correctly closes dialogs when a selection object exists but has no text.

Upstream: anomalyco/opencode#16779 (a64f604)
…kport B6 #17782)

Replace overflow:hidden/text-overflow:ellipsis with overflow-wrap:anywhere
so long descriptions are visible. Remove the now-redundant data-custom override.

Upstream: anomalyco/opencode#17782 (51fcd04)
…2 #17823)

Run Plugin.trigger("experimental.chat.messages.transform") on a
structuredClone of messages before passing them to the compaction model.

Upstream: anomalyco/opencode#17823 (4cb2996)
…port B3 #17064)

Add permission field to StreamInput and merge it with agent permissions
when computing disabled tools. Forward session.permission from prompt.ts.

Upstream: anomalyco/opencode#17064 (c2ca149)
…17812)

Log info and part schema validation failures before persisting to help
diagnose data corruption issues.

Upstream: anomalyco/opencode#17812 (fee3c19)
@e6qu e6qu force-pushed the fix/upstream-backports branch from b6b69bf to 096dd1a Compare March 18, 2026 00:10
@e6qu e6qu merged commit 9715924 into dev Mar 18, 2026
1 check passed
@e6qu e6qu deleted the fix/upstream-backports branch March 18, 2026 00:14
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.

7 participants