Repository navigation
chore(sync): merge upstream v2 through v2.2.0 - #458
Merged
Merged
Conversation
…malyco#58723) Co-authored-by: opencode-agent[bot] <219766164+opencode-agent[bot]@users.noreply.github.com>
Co-authored-by: rekram1-node <rekram1-node@users.noreply.github.com>
…alyco#58769) Co-authored-by: rekram1-node <rekram1-node@users.noreply.github.com>
…alyco#58144) Co-authored-by: Daniel Smolsky <dannysmo@gmail.com>
Co-authored-by: dc85 <83497+dc85@users.noreply.github.com>
…alyco#59151) Co-authored-by: Brendonovich <14191578+Brendonovich@users.noreply.github.com>
…#59148) Co-authored-by: Brendonovich <14191578+Brendonovich@users.noreply.github.com> Co-authored-by: opencode-agent[bot] <219766164+opencode-agent[bot]@users.noreply.github.com>
The v2.2.0 merge dropped the closing of the fork tool-failure test when the upstream video tests were inserted after it.
Heap dump reads the fork ServerSetting tag, and the script env keeps OPENCODE_BUMP and OPENCODE_RELEASE so fork channel and release builds still typecheck.
Upstream replaced the experimental evaluation client and dropped System One from the TypeSafe provider. Keep that fork surface beside the new decision route, re-export the Effect symbols fork tests import from the AI package root, and add the public subagent and permission events to the generated subscribe filter.
|
Review the following changes in direct dependencies. Learn more about Socket for GitHub.
|
The hygiene job matched six `@/home/...` module aliases and a committed C:/Users/Lukem profiler import. Name the alias segments in the allowlist, import @jridgewell/trace-mapping instead, and make the release scripts pass shellcheck once that later step can run.
The cached runtime can call every active tool, including direct tools that are not in the code-mode catalog. Keying the cache on catalog names alone kept a disabled direct tool callable from a later snapshot.
Replace the global text rules for /home/projects, /home/start, /home/sessions, and /home/route with pii entries for the files that import those aliases.
Record the @opencode/ai wildcard subpaths that upstream anomalyco#59183 no longer exports.
An is_error tool_result that also carries image or document blocks is rejected. Keep the error text and replace each non-text item with a note so the error path never inlines that media.
The base moved in #459 and the pull request could not build a merge commit, so pull request checks did not start. Keep that reconnect behavior and the browser skill permission from this branch. # Conflicts: # packages/plugin-browser/src/connection.ts
This was referenced Oct 29, 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.
Issue for this PR
Sync of
integration-v2with upstream OpenCode tagv2.2.0. No tracked issue.Type of change
Upstream sync. Not a product bug fix or feature.
What does this PR do?
Merges upstream tag
v2.2.0(1097e2668b1e08ad63bdf0b1c4860b9bc01e420c,release: v2.2.0, 2026-10-27) intointegration-v2.upstream/v2stopped at4617210822on 2026-10-10 (chore(core): refresh bundled models.dev snapshot). That commit is an ancestor of the tag. The tag is not an ancestor ofupstream/v2: 2567 commits are on the tag and not onupstream/v2, and none are onupstream/v2and missing from the tag. V2 development left thev2branch (it now lives on upstreamdev). The release commit itself is off that branch, so this merges the tag, which already contains its v2 ancestry. Merge-base with the fork is74f8d4860f(parent of the previous v2.1.4 release commit). 661 commits are on the tag since that base.Regular merge commit
27e6bf399f(parents6bab70f39aand1097e2668b), plus follow-up commits that repair merge splices and the review findings. No rebase, squash, or force-push. Headb31307725342c04b2a93513b0ba94cb2fa54e59f. That commit also merges the currentintegration-v2so the pull request can build a merge commit after #459.Fork identity kept: package and bin
shuvcode, CLI version2.2.0-shuv.1, other workspaces2.2.0,@shuvcode/*plugins,@opencode-ai/pty0.3.1, ports0x1337/0x1338, ShuvTunnel (https://shuv.zip, routeshuvcode, data dir and websocket subprotocolshuvtunnel) on@opentunnel/*0.6.1via new patches.bun install --frozen-lockfilepasses. Fork publish guard inpackages/cli/script/pack.tsis unchanged.Unmerged historical fork branches were inventoried and left in place. Their dispositions were already recorded on the v2.1.3 and v2.1.4 syncs. None were merged or deleted here.
Conflict resolutions
Mechanical: workspace
package.jsonversions moved from2.1.4to2.2.0, except the CLI, which is2.2.0-shuv.1.bun.lockwas regenerated from the resolved manifests.Flagged, large or behavioral:
packages/cli/src/commands/commands.ts(556 lines),packages/cli/src/framework/spec.ts,packages/cli/src/services/server-connection.ts,packages/cli/test/server-connection.test.ts. Kept the fork global--server/--standaloneflags (ServerSetting/StandaloneSettingapplied once in the runtime). Removed upstream's per-commandglobalFlags. The upstream spec-level flag parse test was dropped. Heap dump readsServerSetting.packages/cli/script/pack.ts. Kept the fork publish guard (preflightForkPublish,requireForkRepository). Did not take upstream's release-archive packer. Upstreamscript/packremains exported for their release scripts.packages/cli/script/build.ts.OPENCODE_TARGET=linux-x64matchesshuvcode-linux-x64via the existingtargetName()prefix.packages/core/src/tool.ts(392). Kept the forkexecuteCallrepair hook (session-context removal and alias resolution) and upstream's code-mode definition cache.packages/core/src/integration.ts(929) andpackages/core/test/integration-refresh.test.ts. Took upstreamcredentials.lockplus a 30s refresh timeout, and kept the forkshuvcodeAuthImport === "access-only"guard both before and inside the lock. Both test suites are in the file.packages/core/src/database/migration.gen.ts,packages/core/schema.json(2236),packages/core/src/session/sql.ts,packages/core/src/session.ts,packages/core/src/session/projector.ts. Fork migration20261005094821_subagent-operationstaysm48. Upstreamsession_allowance, blob, anddrop_session_pendingarem51–m54. Dropped theSessionPendingTabledefinition so it matches the drop migration. KeptSubagentOperationTableand upstream message/blob ref readers. Took upstream snapshot id44bd8ca5-689a-410e-a46a-958eb5accd97.bun run migration -- --checkinpackages/corereported no schema changes.packages/core/src/config/plugin/provider.ts. Uses upstreamoverlayProviderand the fork variant check againstsource.package(notsource.base.package).packages/core/src/session/model-request.ts. Kept the fork error tool-result content path (Buffer.byteLength).packages/ai/src/protocols/anthropic-messages.ts(1716) and its test (2653). Combined fork tool-error text-plus-blocks with upstream video lowering. A follow-up commit closed the tool-failure test that the splice left open.packages/script/src/index.ts. Kept fork channel and<base>-shuv.<n>version resolution. RestoredOPENCODE_BUMPandOPENCODE_RELEASE, which the env-object splice had dropped.packages/client/src/promise/generated/types.ts. Kept the fork indexed prompt body type.packages/server/src/handlers/session.tskeeps bothSessionPromptPayloadandwantsMediaRefs.packages/client/src/effect/api/api.ts(generated).permission.cancelledandsession.tool.subagent.preparedare in the subscribe filter because they are onEventManifest.ServerDefinitions.bun run generateinpackages/clientreproduces those two lines. Durable-onlysession.message.content.updatedandsession.usage.recordedstay out.packages/aievaluation. Upstream deletedexperimental/evaluation*.tsandexperimental/system-one.tsand replaced the TypeSafe provider with a decision route. Restored the evaluation client and System One model, and attachedexperimental.evaluationbesidedecision. Re-exportedLLM,AIError,ToolFailure,LanguageModel,LLMEvent,Message,ToolDefinition, andisRetryablefrom the package root for existing fork imports.check-test.yml, blacksmithrelease.yml/release-dry-run.yml, triage, deploy, bot, and nix check workflows so this PR does not start paid GitHub Actions. Restored forktest.yml(full suite only onv*tags,workflow_call, andworkflow_dispatch). Kepthygiene.yml,typecheck.yml,publish.yml,notify-discord.yml. Left.github/release/*and.github/nix-hashes/*in tree, unwired.services/www/openapi.json,services/www/public/openapi.json, andpackages/gui-extensions/README.mdwith upstream.jevremains in schema and protocol. Branding is onpackages/gui-plugins/README.md.0x1337/0x1338. Took upstreamprocessEnv()which stripsXDG_STATE_HOME. Port conflict text now names the PID whenlsofcan see the listener.How did you verify your code works?
bun install --frozen-lockfilepassed (Bun 1.4.4).packages/corebun run migration -- --check: no schema changes.oxlint: 0 errors (1579 existing warnings).ast-grepscan andsdk-docspassed.bun turbo typecheck --concurrency=2: 40 successful, 40 total. The pre-pushbun run check(lint + typecheck) passed on the pushed head.GITHUB_ACTIONS=false bun turbo test --concurrency=2 --filter='!@opencode/desktop' --filter='!@opencode/update'): 34 packages passed, 34 total, about 10m14s. The Anthropic Messages suite then passed onfd2aa6d477, including the text-only errortool_resultcases. Not run:@opencode/desktop,@opencode/update.Visual
No UI change.
Screenshots / recordings
None.
Checklist
Risks
tool_resultblocks are text only; non-text items become notes such as[image omitted].bun run generate. Strippingpermission.cancelledandsession.tool.subagent.preparedand regenerating puts both lines back..github/releaseand nix hash scripts are present and unused. Fork CI does not call them. A nix build can still fail a hash check, as before.OPENCODE_TARGETshort names now go through theshuvcode-prefix. Forkpublish.ymldoes not setOPENCODE_TARGET.publish.ymlpath.