Skip to content

Refresh the upstream pin to v2.1.4 #528

Closed
1 of 2 issues completed
Closed

Description

@Blind-Striker

Move the SDK's OpenAPI pin from opencode v2.0.32 to v2.1.4 (68bc26b7da1990ce10ffecfbc1e09eb13aa5d824), following spec/SNAPSHOT.md's refresh procedure. On the day the PR goes to review, the newest 2.1.x tag that has stood for 24 hours is prepared again. The PR moves to that tag if its receipt adds nothing new.

Why now: 0.9.0-preview.13 (pinned 2.0.32) breaks against a 2.1.x server. 2.1.x removed the required recent member from compaction messages and events. Observed with preview.13 against a 2.1.4 server:

  • a message list that contains a compaction message fails with OpenCodeTransportException ("malformed success body"; the inner JsonException names the missing recent);
  • each compaction event fails to decode, so the event stream reconnects and loses it. The turn's session.execution.succeeded, published inside that reconnect gap, was lost too, so code waiting for the turn to end hangs.

npm i -g @opencode/cli installs 2.1.4 today. 0.9.0-preview.14 ships on the refreshed pin.

What moves at v2.1.4

  • Operations: 143 → 149, none removed. The additions:
    • debug.heapDump;
    • experimental.mcp.client and experimental.mcp.client.token;
    • experimental.voice.instructions and experimental.voice.models;
    • permission.saved.update.
  • The Restore patch 001-restore-sse-payloads needs a rebase: the context drifted. The defect it repairs (openapi.json no longer documents SSE payloads (V2Event / SessionLogItem) after the effect beta.107 regen anomalyco/opencode#44911) is still present at v2.1.4.
  • Watched sources: 27 of 84 hashes move, and 3 anchors are lost: the authorization middleware's ticket bypass, the @opencode-ai/pty pin (0.2.0 → 0.3.1, daemon protocol still 7), and the session-list query.
  • Schema, breaking for the generated models:
    • providerState, state and providerResultState become native across assistant messages, their parts, and the step, text, reasoning and tool events;
    • recent is removed from compaction;
    • Session.ProviderContext is removed;
    • Credential.Key.configuration is removed;
    • the session-import messages become untyped.
  • Schema, additive:
    • session.archived and session.unarchived events, and archived on the session list and update;
    • streamUsage, retryAfterMs;
    • the experimental config's todo, background_compaction and location_idle_timeout;
    • the voice models.
  • Windows: the default service port becomes 28894 (0x70DE), to stay clear of the port block that WSL mirrored networking reserves.
  • Bun: upstream's packageManager becomes bun@1.4.4.

Scope

Metadata

Metadata

Assignees

No one assigned

    Labels

    dependenciesPull requests that update a dependency file

    Type

    No type

    Projects

    No projects

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions