Skip to content

fix(app): scope session page errors#34254

Merged
Brendonovich merged 12 commits into
devfrom
session-error-boundary
Jul 1, 2026
Merged

fix(app): scope session page errors#34254
Brendonovich merged 12 commits into
devfrom
session-error-boundary

Conversation

@Brendonovich

@Brendonovich Brendonovich commented Jun 27, 2026

Copy link
Copy Markdown
Member

Summary

  • Add an ErrorBoundary inside the session page main panel when new layout designs are enabled, so session load errors do not take down the tab shell.
  • Move target session route resolution into the session page module so target-route failures render inside the session panel frame.
  • Render known session-not-found errors with a stackless not-found panel instead of the generic stack trace error page.
  • Include the server name, missing session ID, and a Close Tab action in the not-found panel.
  • Style the session ID like markdown inline code and keep the server name as regular faint text.
  • Keep session tab metadata fetch failures local to the tab strip and render Unknown Session instead of hiding the tab.
  • Reset the boundary when switching session tabs.

@Brendonovich Brendonovich requested a review from Hona as a code owner June 27, 2026 19:13
@andrei-hasna

Copy link
Copy Markdown

Task-triggered merge review completed for PR #34254.\n\nValidation:\n- GitHub checks are green: check-compliance, check-standards, e2e linux/windows, nix-eval, typecheck, unit linux/windows.\n- Branch is fresh against dev: base ae53163, head 4524101.\n- Local merge-tree against origin/dev succeeded with no conflicts.\n- Clean temp worktree validation passed: app typecheck, targeted i18n/server-errors tests, focused lint with 0 errors, and app production build.\n- Independent adversarial reviewer found no merge blockers; residual risk is lack of dedicated UI regression coverage for the new session error fallback / Unknown Session tab behavior.\n\nMerge blocker:\n- Attempted squash merge pinned to reviewed head SHA 4524101, but GitHub rejected it: authenticated user andrei-hasna lacks MergePullRequest permission on anomalyco/opencode.\n\nNo files were mutated in the main checkout by this review.

@andrei-hasna

andrei-hasna commented Jun 28, 2026

Copy link
Copy Markdown

Task-triggered merge review refreshed for PR #34254.

Current state checked on 2026-06-28:

  • PR is open, not draft, MERGEABLE / CLEAN.
  • Head: 4524101 (session-error-boundary).
  • Current dev: 61a7f6d, newer than PR metadata base ae53163.
  • GitHub checks are passing: check-compliance, check-standards, e2e linux/windows, nix-eval, typecheck, unit linux/windows.
  • Local synthetic merge into current dev succeeded with no conflicts.
  • Local validation in /tmp/opencode-pr34254.YX5OEY passed: bun run --cwd packages/app typecheck; bun test --preload ./packages/app/happydom.ts ./packages/app/src/utils/server-errors.test.ts (12 pass); focused oxlint on changed files (0 errors); bun run --cwd packages/app build.
  • Secret-pattern scan on the PR diff found no configured token patterns.
  • Independent adversarial reviewer found no merge blockers.

Merge blocker:

  • Pinned squash merge attempt failed: GraphQL reported that andrei-hasna does not have permission to execute MergePullRequest. The authenticated account has READ permission on anomalyco/opencode, so this worker cannot complete the merge.

No files were mutated in the main checkout by this review.

@andrei-hasna

Copy link
Copy Markdown

Task-triggered merge review refreshed for PR #34254 on 2026-06-28.

Current state:

  • PR is open, not draft, and GitHub reports MERGEABLE / CLEAN.
  • Head: 4524101 (session-error-boundary).
  • Current dev: dfeb1b5.
  • GitHub checks are passing: check-compliance, check-standards, e2e linux/windows, nix-eval, typecheck, unit linux/windows.
  • Local synthetic merge into current origin/dev succeeded with no conflicts.
  • Local validation in a clean temp worktree passed:
    • bun run --cwd packages/app typecheck
    • bun test --preload ./packages/app/happydom.ts ./packages/app/src/utils/server-errors.test.ts (12 pass)
    • focused oxlint on changed files (0 errors, existing warnings only)
    • bun run --cwd packages/app build
  • Secret-pattern scan on the PR diff found no configured token patterns.
  • Independent adversarial verifier found no merge blockers.

Residual non-blocking risk:

  • titlebar-tab-strip.tsx currently treats any session.resolve() failure as missing, so a transient network/server/auth failure can show Unknown Session. Tracked separately as follow-up; not a merge blocker for this PR.

Merge blocker:

  • The authenticated account andrei-hasna has READ permission on anomalyco/opencode; GraphQL reports viewerCanUpdate=false and viewerCanMergeAsAdmin=false. This worker cannot merge PR fix(app): scope session page errors #34254.

No files were mutated in the main checkout by this review.

@andrei-hasna

andrei-hasna commented Jun 28, 2026

Copy link
Copy Markdown

OpenLoops merge review for task ae9bc65e is ready but blocked by permissions.

Validation completed on current dev:

  • Live PR state: OPEN, MERGEABLE/CLEAN, all GitHub checks green.
  • PR head: 4524101. Current dev checked locally: 58ba99e. The branch is behind dev, but a local no-commit merge onto current dev applied cleanly.
  • bun install --frozen-lockfile passed.
  • From packages/app: bun run typecheck passed.
  • Focused app unit tests passed: bun test --preload ./happydom.ts ./src/utils/server-errors.test.ts ./src/i18n/parity.test.ts ./src/components/titlebar-tab-gesture.test.ts ./src/context/tabs.test.ts (18/18).
  • bun run build passed with existing Vite chunk/dynamic-import warnings.
  • Production first-navigation benchmark was run before and after this PR with PLAYWRIGHT_WORKERS=1 bunx playwright test --config e2e/performance/playwright.config.ts timeline/first-navigation-benchmark.spec.ts; both runs passed 3/3 with zero blank/unknown samples.
  • Read-only adversarial review: PASS, no merge blockers. Residual risk noted: the new-layout panel boundary will also render inline fallback for future programming errors inside the panel.
  • Staged secret scan and git diff --check passed.

Merge attempt used a head-SHA guard and failed only because active GitHub user andrei-hasna lacks MergePullRequest permission on anomalyco/opencode:

gh pr merge 34254 --repo anomalyco/opencode --squash --subject "fix(app): scope session page errors" --body "" --match-head-commit 4524101689fc164d1b0138d278815e07981f4ff5

Follow-up todos task 445aa140-3781-4b9b-a765-4d092807de36 tracks merge by an authorized GitHub identity. Please rerun a final live status/head check before merging if the head changes.

@Brendonovich Brendonovich merged commit 5e1a1ed into dev Jul 1, 2026
10 checks passed
@Brendonovich Brendonovich deleted the session-error-boundary branch July 1, 2026 07:04
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.

2 participants