Skip to content

fix: resolve worktree and Evaluation follow-ups - #480

Merged
shuv1337 merged 8 commits into
integration-v2from
fix-issue-474-followups
Nov 10, 2026
Merged

shuv1337 merged 8 commits into
integration-v2from
fix-issue-474-followups

Conversation

@shuv1337

@shuv1337 shuv1337 commented Nov 10, 2026 •

Copy link
Copy Markdown
Owner

Summary

Closes #474.

Checked every item against 0048b70a92 (2.2.6-shuv.2, including #477/#479) before changing it. Full evidence and the focused security/access-flow assessment are in docs/issue-474-followups.md.

Item Disposition
run --worktree setup hangs Fixed here. Pass the bounded client to worktree setup and wrap worktree.create. Stalled lookup and create now fail with clear phase-specific timeouts; prompt execution/event streaming stay unbounded.
Experimental Evaluation/System One drops per-call headers Fixed here. Preserve top-level headers through schema construction and normalization. Merge configuration → per-call (case-insensitively) → authentication, matching existing transport behavior. Document that historical http.headers is unsupported.
MCP refresh failure leaves sign-in waiting Resolved earlier. f39aa60608 (upstream anomalyco#62102), included in #477, adds retryable refresh failures/timeouts. Re-ran its production-build browser regressions from both dialog and popover; no duplicate fix.
OAuth/permission-flow review Completed here. No demonstrated vulnerability and no runtime policy changes. Assessed callback state/PKCE/issuer handling, one-shot completion, cancellation/expiry, injected fetch and credential refresh, and permission precedence. Added an injected-fetch boundary regression. #479 already includes shared credential-lock refresh (66071f9edd).
OpenAPI drift Fixed here. Generated the missing permission.cancelled and session.tool.subagent.prepared schemas/references. Client generation rerun; no client diff.

Feature flag: none; regression fixes, tests, documentation, and generated-document reconciliation only.

Verification

  • Frozen installation; lockfile unchanged.
  • Before-fix reproductions: both worktree subprocess cases hung until the watchdog killed them; both Evaluation transport cases lost the sentinel header. All pass after the fixes.
  • bun run check: lint and 39/39 typecheck tasks passed.
  • bun run typecheck:tsc: 32/32 tasks passed.
  • Effect simplification rules 10/10, lint-rule tests 6/6, OpenAPI generation check and git diff --check passed.
  • CLI setup suite: 17/17 on source, 17/17 compiled Bun, 17/17 compiled Node. New worktree cases repeated ten times: 20/20.
  • Evaluation transport regressions repeated ten times: 20/20. Injected-fetch test repeated ten times: 10/10.
  • MCP OAuth, integration, permission and plugin-permission focused suites: 183/183.
  • Production-build Playwright MCP refresh-recovery tests: 2/2, then 20/20 across five workers, no retries.
  • Linux x64 Bun and Node SEA builds and isolated compiled service-lifecycle smoke tests passed (registration/election, authentication, embedded web UI, MCP socket, plugin discovery and shutdown).
  • Broad validation: 36/36 non-Core Turbo test tasks passed, including full CLI (457 tests) and TUI (1,737 passed, 2 skipped) suites. Core passed in its isolated network namespace: 7,406 passed, 27 skipped, zero failed.

Final execution checks use throwaway HOME/XDG/database state, loopback fixtures or in-page API mocks. No live Shuvcode service was targeted or stopped. The first broad run encountered an unrelated host listener on GitLab OAuth's fixed callback port 8080; it was left alone and Core passed in a disposable network namespace after dropping capabilities (otherwise root invalidates two filesystem-permission tests). The exact command is in the checked-in report.

The release smoke script initially inherited OPENCODE_CONFIG_DIR despite replacing HOME/XDG. Fixed that test-isolation gap with the existing cleanProcessEnv() helper and a disposable cwd. Deliberately invalid throwaway config plus disabled project-config discovery fails the old smoke script and passes the corrected script for both compiled runtimes.

Deferred: macOS/Windows/ARM release-matrix execution to release CI; this Linux x64 host cannot execute those native artifacts. No merge or release performed.

Visual

<svg xmlns="http://www.w3.org/2000/svg" width="240" height="72" viewBox="0 0 240 72">
  <style>@keyframes pulse{50%{opacity:.3}}.pulse{animation:pulse 2s ease-in-out infinite}@media(prefers-reduced-motion:reduce){.pulse{animation:none}}</style>
  <rect x="4" y="4" width="232" height="64" rx="8" fill="currentColor" opacity=".06"/>
  <g fill="currentColor" font-family="sans-serif" font-size="12">
    <text x="14" y="27">Setup: bounded</text>
    <text x="14" y="53">Headers: forwarded</text>
  </g>
  <g class="pulse" fill="none" stroke="currentColor" stroke-width="2">
    <circle cx="213" cy="23" r="9"/><path d="M213 17v6l4 3M198 49h24m-6-5 6 5-6 5"/>
  </g>
</svg>

Review fixes

  • Worktree creation now uses the 120-second admission deadline, allowing project start commands to finish; timeout errors warn that the worktree may already exist and to check before retrying. Updated the subprocess expectation and recorded the decision.
  • Clarified that the setup wrapper bounds worktree creation as well as session-target resolution.
  • Documented Evaluation/System One as intentionally fork-only for jev.systemOne (feat(core): add experimental jev.systemOne session tool #397), following upstream removal in feat(ai): replace experimental evaluation with Decision anomalyco/opencode#58758 (097a93e511) in favour of Decision.
  • Checks: setup 17/17, worktree-create regression 10/10 repetitions, Evaluation 2/2, MCP OAuth 33/33; bun run check passed (39/39 typecheck tasks; lint warnings, no errors), touched-file Prettier and git diff --check passed.

@shuv1337
shuv1337 merged commit f3b2376 into integration-v2 Nov 10, 2026
5 checks passed
@shuv1337
shuv1337 deleted the fix-issue-474-followups branch November 10, 2026 00:13
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.

Follow up PR #473: worktree timeout and Evaluation header regressions

1 participant