Skip to content

chore(deps): upgrade Effect to stable 4.0.1 - #16138

Merged
juliusmarminge merged 4 commits into
mainfrom
t3code/effect-4.0.1
Oct 5, 2026
Merged

juliusmarminge merged 4 commits into
mainfrom
t3code/effect-4.0.1

Conversation

@juliusmarminge

@juliusmarminge juliusmarminge commented Oct 5, 2026 •

Copy link
Copy Markdown
Member

Moves Effect from 4.0.0-rc.115 to stable 4.0.1, without waiting for OpenCode to move off the release candidates. 4.0.1 includes several fixes we sent upstream (interrupted Effect.cached/Cache lookups, idle groupedWithin ticking, sqlite-node prepare caching, RpcClient stream buffers on interrupt). This replaces #14914, which targeted 4.0.0 and is 170 commits behind main.

Changes

  • Imports. 4.0 removes the effect/unstable/* paths: every import moves to effect/<area> (httpapi becomes http-api), and effect/Encoding is split into effect/encoding/{Base64,Base64Url,Hex}. This is the bulk of the 834 files and was done with a script.

  • Dependencies.

    • effect and every @effect/* package at 4.0.1.
    • Alchemy 2.0.0-beta.80 and distilled 1.0.0-rc.13, which ship the new layout.
    • OpenCode 2 (@opencode/client, protocol, schema) at 2.0.23, patched. They still import the removed paths, Encoding and Schema.isStartsWith, and their statics helper assigned over a schema's make, which 4.0 caches as a non-configurable property. Drop the patches once OpenCode targets stable Effect.
  • Behavior changes picked up from rc.116 through 4.0.1:

    • HttpRouter.serve builds the app in a private memo map, so TracerDisabledWhen is provided to the served layer.
    • Scope.close requires a closeable scope: SSH tunnels and the ACP and Antigravity runtimes close a scope they own.
    • RpcSerialization.ndJsonRpc skips non-JSON lines, so effect-acp decodes each frame with the strict codec to keep failing on a malformed agent line.
    • Effect.partition returns successes first; Stream.scan takes a lazy initial state; SchemaGetter.onSome/.compose are replaced; Schema.brand needs a single concrete brand key.
    • A declared MCP tool failure is isError with JSON text, without structuredContent; the MCP tests read it there.
  • Patches. effect@4.0.1.patch is down to three changes, each sent upstream so it can be dropped:

    The RpcClient RequestHooks and onPing/onPong/onPingTimeout hooks are dropped: nothing has used them since the client connection rewrite in [codex] Rewrite client connection architecture #2978. 4.0.1 has its own fix for a busy stream blocking the socket on interrupt, so ours is dropped too. The Alchemy patch applies unchanged.

  • @effect/vitest patch. Besides importing vite-plus/test, it now drops the package's vitest peer. Left in, pnpm auto-installed a second vitest for it, and that one pulled in real vite@8.3.2 and another rolldown, because our vite → vite-plus-core override doesn't reach auto-installed peers. Nothing imported it.

Verification

  • tsc --noEmit clean in all 12 packages: contracts, shared, effect-acp, effect-codex-app-server, client-runtime, ssh, tailscale, server, desktop, web, mobile, relay.
  • vp test run:
    • contracts 510, shared 1105, effect-acp 70, effect-codex-app-server 36, client-runtime 1998, ssh 35, tailscale 14, relay 345, desktop 1208 — all pass.
    • server 6411 passed, 8 failed; web 5802 passed, 3 failed; mobile 1932 passed, 1 failed. The same tests fail on a clean checkout of main on this machine: macOS /var vs /private/var temp paths, symlink resolution, the root .env leaking a Clerk client id into connectCliAuth.test.ts, and the Swift TSan fixtures.
  • OpenCode2Client.live.test.ts against a real OpenCode 2.0.23 server: passes (server info, one turn, history paging), so the patched client decodes the live API under 4.0.1. Its pinned server version moves to 2.0.23.
  • knip clean.

Not in this PR: syncing .repos/effect-smol to 4.0.1 (separate refs PR).

Model/harness: Claude Opus 5.5 (1M context) via Claude Code in T3 Code.

🤖 Generated with Claude Code


Devin Review

Effect 4.0 drops the `effect/unstable/*` export paths, so every import
moves to its flattened `effect/<area>` path (`httpapi` becomes `http-api`),
and `effect/Encoding` is split into `effect/encoding/{Base64,Base64Url,Hex}`.

Dependencies that still target the release candidates:
- Alchemy 2.0.0-beta.80 and distilled 1.0.0-rc.13 ship the new layout.
- OpenCode 2 (@opencode/client, protocol, schema) moves to 2.0.23 and is
  patched: it still imports the removed paths, `Encoding` and
  `Schema.isStartsWith`, and its `statics` helper assigned over a schema's
  `make`, which 4.0 caches as a non-configurable property. Drop the
  patches once OpenCode targets stable Effect.
- Drizzle's Effect integration only references the old paths in .d.ts
  files and loads unchanged.

Behavior changes from rc.116 through 4.0.1:
- `HttpRouter.serve` builds the app in a private memo map, so the server's
  `TracerDisabledWhen` predicate is provided to the served layer. Services
  from layers around `serve` win over the app's own, so the static-file
  test provides its FileSystem between `serve` and the test server.
- `Scope.close` requires a closeable scope: SSH tunnels take their entry
  scope explicitly, and the ACP and Antigravity runtimes close a child of
  the caller's scope.
- `RpcSerialization.ndJsonRpc` skips lines that are not JSON, so effect-acp
  decodes each frame with the strict codec to keep failing sessions on a
  malformed agent line.
- `Effect.partition` returns successes first; `Stream.scan` takes a lazy
  initial state; `SchemaGetter.onSome`/`.compose` are replaced;
  `Schema.brand` requires a single concrete brand key.
- A declared MCP tool failure is returned as `isError` with its payload as
  JSON text, without `structuredContent`; the MCP tests read it there.

The effect patch is re-ported. It keeps MCP session DELETE, the RpcClient
request and connection hooks, the missed-pong tolerance and the React
Native `getSetCookie` guard. 4.0.1 ships its own fix for a busy stream
blocking the socket on interrupt, so the patch's version of that is gone.

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
@github-actions github-actions Bot added vouch:trusted PR author is trusted by repo permissions or the VOUCHED list. size:XXL 1,000+ changed lines (additions + deletions). labels Oct 5, 2026
@juliusmarminge juliusmarminge added the macroscope-review Opt PRs made by unvouched contributors in for Macroscope review. Vouched contributors auto-reviews label Oct 5, 2026
@macroscopeapp

macroscopeapp Bot commented Oct 5, 2026 •

Copy link
Copy Markdown
Contributor

Approvability

Verdict: Not approved

Macroscope's review found this PR not approvable — This is a broad Effect runtime upgrade spanning production desktop, mobile, web, server, relay, and shared code, with additional process-lifecycle, parser, tracing, and authentication-path changes plus patched third-party packages. The sensitive authentication-directory changes and non-mechanical runtime adaptations make the blast radius unsuitable for automatic approval.

You can add or adjust custom eligibility rules. Learn more.

@github-actions

github-actions Bot commented Oct 5, 2026 •

Copy link
Copy Markdown
Contributor

Thread transfer impact

✅ Thread transfer remains within every enforced ceiling.

ℹ️ The exact PR base did not have a successful artifact. Baseline uses the latest successful main measurement shown below.

Provider Metric Main baseline This PR Impact PR ceiling
Codex Total thread wire 4.9 KiB 5.0 KiB +122 B (+2.5%) 6.8 KiB ✅
Codex Thread snapshot wire 3.7 KiB 3.8 KiB +81 B (+2.1%) 4.9 KiB ✅
Codex Live turn WebSocket wire 1.1 KiB 1.2 KiB +41 B (+3.5%) 2.0 KiB ✅
Codex Live turn WebSocket decoded 20.4 KiB 20.9 KiB +482 B (+2.3%) 29.3 KiB ✅
Codex Live turn messages 1 2 +1 (+100.0%) 8 ✅
Claude Total thread wire 4.9 KiB 5.0 KiB +59 B (+1.2%) 6.8 KiB ✅
Claude Thread snapshot wire 3.7 KiB 3.8 KiB +82 B (+2.2%) 4.9 KiB ✅
Claude Live turn WebSocket wire 1.2 KiB 1.2 KiB −23 B (−1.9%) 2.0 KiB ✅
Claude Live turn WebSocket decoded 20.8 KiB 21.2 KiB +400 B (+1.9%) 29.3 KiB ✅
Claude Live turn messages 2 1 −1 (−50.0%) 8 ✅

Baseline: ce90eec · PR result: da1038c · Source CI: failure

Scenario and decoded snapshot size

10 historical turns, 5 command tools per turn, 878.9 KiB retained MCP result per historical turn, and a 1.05 MiB retained result in the measured turn.

  • Codex decoded thread snapshot: 108.5 KiB
  • Claude decoded thread snapshot: 108.8 KiB

Updated in place by a trusted workflow. PR artifacts are strictly validated and never executed.

juliusmarminge and others added 3 commits October 5, 2026 11:15
RequestHooks and the ConnectionHooks onPing/onPong/onPingTimeout callbacks
have had no callers since the client connection rewrite (#2978). The
patch now carries only MCP session DELETE (upstream: Effect-TS/effect#8773),
the getSetCookie guard (Effect-TS/effect#8772) and the missed-pong
tolerance (Effect-TS/effect#8774).

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
@effect/vitest 4.0.1 declares vitest as a peer. pnpm auto-installed one
for it, and that vitest brought real vite@8.3.2 with its own rolldown,
since the vite → vite-plus-core override does not reach auto-installed
peers. Our patch already makes @effect/vitest import vite-plus/test, so
the patch now also drops the unused vitest peer, and the
peerDependenciesMeta extension that only marked it optional goes away.

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
A catalog: spec in packageExtensions resolves only when the same name
has a catalog: override, which is why vite-plus@*'s vite entry worked
and @effect/vitest's vite-plus one did not. Add a vite-plus catalog
override so @effect/vitest can use catalog: like everything else, and
every vite-plus in the tree resolves to the one catalog version.

The vite-plus@* extension is dropped: vite-plus already depends on
vite-plus-core, so it changed nothing but the extensions checksum.

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
@juliusmarminge
juliusmarminge merged commit 194c73f into main Oct 5, 2026
46 of 48 checks passed
@juliusmarminge
juliusmarminge deleted the t3code/effect-4.0.1 branch October 5, 2026 20:15
saphid pushed a commit to saphid/t3code that referenced this pull request Oct 5, 2026
Resolves the conflict with the Effect 4.0.1 upgrade (pingdotgg#16138): reactivity and
sql modules dropped their unstable/ prefix.

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
github-actions Bot added a commit to omarcresp/t3code-flake that referenced this pull request Oct 6, 2026
## What's Changed
* chore(deps): upgrade Effect to stable 4.0.1 by @juliusmarminge in pingdotgg/t3code#16138
* fix(server): worktree threads survive a local branch named t3code by @juliusmarminge in pingdotgg/t3code#16167
* chore(refs): sync Effect and Alchemy references to 4.0.1 and beta.80 by @juliusmarminge in pingdotgg/t3code#16170
* fix(web): match subagent timestamp fonts to chat by @StiensWout in pingdotgg/t3code#16151
* fix(web): wrap full status text in composer hover details by @UtkarshUsername in pingdotgg/t3code#16158
* ci: run the transfer report job on Blacksmith by @juliusmarminge in pingdotgg/t3code#16178
* fix(server): Stop also stops delegated tasks and pull request watches by @t3dotgg in pingdotgg/t3code#16002
* feat: native /goal for Codex and Claude, with goal status in the UI by @t3dotgg in pingdotgg/t3code#15592
* fix(server): name the cause of a failed git command by @walid-baharwal in pingdotgg/t3code#8645
* fix(server): PR watch wakes the agent when a bot edits its review comment by @Gigioxx in pingdotgg/t3code#15415
* feat(source-control): omit agent credits from PR merge messages by @juliusmarminge in pingdotgg/t3code#16192
* fix(clients): dropped connections say why in the client trace by @t3dotgg in pingdotgg/t3code#16200
* fix(server): PR watch reports a required check that first appears already passed by @ScottN-PV in pingdotgg/t3code#15804
* fix: a failed DPoP key load and a fresh maintenance read are no longer cached by @juliusmarminge in pingdotgg/t3code#15500
* fix: tool screenshots show as images, not base64 text by @t3dotgg in pingdotgg/t3code#16199
* docs(mcp): thread tools reach threads in any project by @t3dotgg in pingdotgg/t3code#15947
* fix(threads): threads watching a PR stay in Working instead of bouncing to the inbox by @t3dotgg in pingdotgg/t3code#16204
* chore(deps): bump cursor sdk and astro to clear vulnerable transitives by @juliusmarminge in pingdotgg/t3code#16214
* fix(server): PR sync waits out a GitHub rate limit pause instead of failing every PR by @t3dotgg in pingdotgg/t3code#16203
* feat(server): scheduled tasks can run on a webhook by @juliusmarminge in pingdotgg/t3code#15085
* feat(relay): forward webhook requests to the environment's tunnel by @juliusmarminge in pingdotgg/t3code#15086
* feat(mobile): create and copy webhook automations by @juliusmarminge in pingdotgg/t3code#15087
* feat(web): create webhook automations and inspect their deliveries by @juliusmarminge in pingdotgg/t3code#15088
* feat(relay,server,web,mobile): opt-in to hold webhooks while offline by @juliusmarminge in pingdotgg/t3code#15487
* fix(server): PR watches stop burning GitHub's rate limit and giving up by @t3dotgg in pingdotgg/t3code#16208
* fix(server): delegation sees a fixed provider without the app open by @t3dotgg in pingdotgg/t3code#16219
* feat: new branches use the shorter t3/ prefix by @t3dotgg in pingdotgg/t3code#16220
* perf: cheaper shell refreshes, one copy of Codex streaming text, no MCP wait polling by @t3dotgg in pingdotgg/t3code#15033
* feat: agents can show HTML pages inline in threads by @t3dotgg in pingdotgg/t3code#15968
* chore(relay): match Alchemy to the PS-80 Postgres cluster by @juliusmarminge in pingdotgg/t3code#16228
* feat: agents ask the user for a secret through a private card by @juliusmarminge in pingdotgg/t3code#15907
* feat(web): see and stop pull request watches in the thread details card by @t3dotgg in pingdotgg/t3code#16235
* fix(server): ACP mode states with null descriptions are no longer dropped by @juliusmarminge in pingdotgg/t3code#16218
* fix(server): finished outbox rows and old PR cache files are pruned by @juliusmarminge in pingdotgg/t3code#16247
* fix(relay): releasing a tunnel that still has a connector no longer 500s by @juliusmarminge in pingdotgg/t3code#16250

## New Contributors
* @ScottN-PV made their first contribution in pingdotgg/t3code#15804

**Full Changelog**: pingdotgg/t3code@v0.0.46-nightly.20261005.2689...v0.0.46-nightly.20261005.2702

Upstream release: https://github.com/pingdotgg/t3code/releases/tag/v0.0.46-nightly.20261005.2702
github-actions Bot added a commit to davidvanderklay/t3code-flake that referenced this pull request Oct 6, 2026
## What's Changed
* chore(deps): upgrade Effect to stable 4.0.1 by @juliusmarminge in pingdotgg/t3code#16138
* fix(server): worktree threads survive a local branch named t3code by @juliusmarminge in pingdotgg/t3code#16167
* chore(refs): sync Effect and Alchemy references to 4.0.1 and beta.80 by @juliusmarminge in pingdotgg/t3code#16170
* fix(web): match subagent timestamp fonts to chat by @StiensWout in pingdotgg/t3code#16151
* fix(web): wrap full status text in composer hover details by @UtkarshUsername in pingdotgg/t3code#16158
* ci: run the transfer report job on Blacksmith by @juliusmarminge in pingdotgg/t3code#16178
* fix(server): Stop also stops delegated tasks and pull request watches by @t3dotgg in pingdotgg/t3code#16002
* feat: native /goal for Codex and Claude, with goal status in the UI by @t3dotgg in pingdotgg/t3code#15592
* fix(server): name the cause of a failed git command by @walid-baharwal in pingdotgg/t3code#8645
* fix(server): PR watch wakes the agent when a bot edits its review comment by @Gigioxx in pingdotgg/t3code#15415
* feat(source-control): omit agent credits from PR merge messages by @juliusmarminge in pingdotgg/t3code#16192
* fix(clients): dropped connections say why in the client trace by @t3dotgg in pingdotgg/t3code#16200
* fix(server): PR watch reports a required check that first appears already passed by @ScottN-PV in pingdotgg/t3code#15804
* fix: a failed DPoP key load and a fresh maintenance read are no longer cached by @juliusmarminge in pingdotgg/t3code#15500
* fix: tool screenshots show as images, not base64 text by @t3dotgg in pingdotgg/t3code#16199
* docs(mcp): thread tools reach threads in any project by @t3dotgg in pingdotgg/t3code#15947
* fix(threads): threads watching a PR stay in Working instead of bouncing to the inbox by @t3dotgg in pingdotgg/t3code#16204
* chore(deps): bump cursor sdk and astro to clear vulnerable transitives by @juliusmarminge in pingdotgg/t3code#16214
* fix(server): PR sync waits out a GitHub rate limit pause instead of failing every PR by @t3dotgg in pingdotgg/t3code#16203
* feat(server): scheduled tasks can run on a webhook by @juliusmarminge in pingdotgg/t3code#15085
* feat(relay): forward webhook requests to the environment's tunnel by @juliusmarminge in pingdotgg/t3code#15086
* feat(mobile): create and copy webhook automations by @juliusmarminge in pingdotgg/t3code#15087
* feat(web): create webhook automations and inspect their deliveries by @juliusmarminge in pingdotgg/t3code#15088
* feat(relay,server,web,mobile): opt-in to hold webhooks while offline by @juliusmarminge in pingdotgg/t3code#15487
* fix(server): PR watches stop burning GitHub's rate limit and giving up by @t3dotgg in pingdotgg/t3code#16208
* fix(server): delegation sees a fixed provider without the app open by @t3dotgg in pingdotgg/t3code#16219
* feat: new branches use the shorter t3/ prefix by @t3dotgg in pingdotgg/t3code#16220
* perf: cheaper shell refreshes, one copy of Codex streaming text, no MCP wait polling by @t3dotgg in pingdotgg/t3code#15033
* feat: agents can show HTML pages inline in threads by @t3dotgg in pingdotgg/t3code#15968
* chore(relay): match Alchemy to the PS-80 Postgres cluster by @juliusmarminge in pingdotgg/t3code#16228
* feat: agents ask the user for a secret through a private card by @juliusmarminge in pingdotgg/t3code#15907
* feat(web): see and stop pull request watches in the thread details card by @t3dotgg in pingdotgg/t3code#16235
* fix(server): ACP mode states with null descriptions are no longer dropped by @juliusmarminge in pingdotgg/t3code#16218
* fix(server): finished outbox rows and old PR cache files are pruned by @juliusmarminge in pingdotgg/t3code#16247
* fix(relay): releasing a tunnel that still has a connector no longer 500s by @juliusmarminge in pingdotgg/t3code#16250

## New Contributors
* @ScottN-PV made their first contribution in pingdotgg/t3code#15804

**Full Changelog**: pingdotgg/t3code@v0.0.46-nightly.20261005.2689...v0.0.46-nightly.20261005.2702

Upstream release: https://github.com/pingdotgg/t3code/releases/tag/v0.0.46-nightly.20261005.2702
AmbitiousRealism2025 added a commit to AmbitiousRealism2025/t3.14-t3code that referenced this pull request Oct 6, 2026
Merges upstream/main up to ac8e945 (123 commits since the fork base
7812230). The upstream commits are kept as they are; against upstream,
the result differs only in the 19 T3.14 files.

Two textual conflicts (ProviderTurnStartService imports, server.ts layer
naming), plus twelve renames and moves from upstream pingdotgg#16295, pingdotgg#16282 and
pingdotgg#16138 fixed in T3.14 code. No behavior change. 334 tests pass, and the
merged server boots with a durable Pi instance. Codex: no major issues.

Running the fork now needs `T3_SERVICE_LAUNCHER_CONTEXT` unset when it is
started from a shell an installed T3 launched.

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

macroscope-review Opt PRs made by unvouched contributors in for Macroscope review. Vouched contributors auto-reviews size:XXL 1,000+ changed lines (additions + deletions). vouch:trusted PR author is trusted by repo permissions or the VOUCHED list.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant