Skip to content

Add persisted session upgrade fixture gate - #7007

Closed
brennanb2025 wants to merge 1 commit into
brennanb2025/fix-terminal-reliabilityfrom
brennanb2025/reliability-upgrade-fixtures
Closed

brennanb2025 wants to merge 1 commit into
brennanb2025/fix-terminal-reliabilityfrom
brennanb2025/reliability-upgrade-fixtures

Conversation

@brennanb2025

@brennanb2025 brennanb2025 commented Jul 1, 2026 •

Copy link
Copy Markdown
Contributor

Summary

  • Add a small text-based 1.4.65-shaped workspaceSession fixture with documented provenance for the persisted-session upgrade corpus.
  • Add a focused renderer-state gate that parses the fixture through the shared schema, hydrates/reconnects the store, and rejects blank replacement tabs, duplicate tabs, lost legacy PTY wake hints, or eager startup spawning.
  • Register the startup-upgrade.persisted-session-corpus command in config/reliability-gates.jsonc with updated performance evidence and known gaps; maturity remains experimental.

ELI5

Older versions of Orca saved workspace/session data in slightly different shapes. When a newer Orca opens that old data, it should restore the real tabs and sessions instead of making blank tabs, duplicates, or launching things too early. This PR adds an old saved-session fixture and a test that proves the upgrade path still restores it safely.

Why We Need This

This covers the startup/upgrade persisted-session class. Users can open Orca with workspace/session data saved by older versions, and that data must not produce blank replacement tabs, duplicate tabs, lost PTY wake hints, or eager startup spawning.

Product Code vs Gate Coverage

This PR is fixture/gate coverage, not a runtime upgrade-path change. It adds a legacy saved-session fixture and focused hydration tests against the current schema/store path. The manifest keeps full Electron boot, second restart, SSH, and WSL upgrade coverage as explicit follow-up gaps.

Merge Order

Requires #7001 first because this PR updates the reliability gate manifest introduced there.

After #7001 lands, this PR can merge independently of #7004, #7005, #7006, and #7008. No other child PR must merge before this one. Later child PRs may need a normal manifest rebase if this one lands first.

Validation

  • pnpm run check:reliability-gates
  • pnpm exec vitest run --config config/vitest.config.ts src/renderer/src/store/slices/persisted-session-upgrade-fixture.test.ts src/shared/workspace-session-schema.test.ts
  • pnpm exec oxlint src/renderer/src/store/slices/persisted-session-upgrade-fixture.test.ts
  • pnpm run typecheck:web
  • git diff --check

Residual Risks

  • This is the first lower-layer fixture gate, not a full Electron boot against copied user-data.
  • Second restart after current-write, explicit unrecoverable marking, SSH, and WSL fixture coverage remain listed as manifest gaps.
  • Red/green evidence is still partial until an intentional-break artifact is saved.

Made with Orca 🐋


Open in Stage

Post-PR Stabilization

  • CI checks pass after the post-PR wait.
  • PR comments and review-comment surfaces were checked; no actionable automated review comments remain.

@ghost

ghost commented Jul 1, 2026

Copy link
Copy Markdown

Ready to review this PR? Stage has broken it down into 3 individual chapters for you:

Title
1 Define legacy workspace session upgrade fixtures
2 Implement renderer-state hydration gate test
3 Register persisted session upgrade reliability gate
Open in Stage

Chapters generated by Stage for commit 69762e1 on Jul 1, 2026 8:24am UTC.

@brennanb2025

Copy link
Copy Markdown
Contributor Author

Closing as superseded: a merged PR already covers this change. Main config/reliability-gates.jsonc:11363 already registers gate startup-upgrade.persisted-session-corpus, backed by a stronger Electron e2e upgrade journey (tests/e2e/persisted-session-production-upgrade.spec.ts) added by #17289

(Stale-PR cleanup 2026-10-20, approved by Brennan. Reopen if something here is still missing on main.)

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.

1 participant