mirror of
https://github.com/stablyai/orca.git
synced 2026-10-13 00:02:54 +00:00
chore: archive auto-review context for fix-session-hydration-data-loss
Co-authored-by: Orca <help@stably.ai>
This commit is contained in:
@@ -1,77 +0,0 @@
|
||||
# Review Context
|
||||
|
||||
## Branch Info
|
||||
|
||||
- Base: origin/main
|
||||
- Current: brennanb2025/fix-session-hydration-data-loss
|
||||
- Merge base: 8e44541c4c53cfdf6bb149dc7dc4524eff24405a
|
||||
|
||||
## Changed Files Summary
|
||||
|
||||
- M src/main/persistence.test.ts
|
||||
- M src/main/persistence.ts
|
||||
- M src/renderer/src/App.tsx
|
||||
- M src/renderer/src/lib/workspace-session.test.ts
|
||||
- M src/renderer/src/lib/workspace-session.ts
|
||||
- M src/renderer/src/store/slices/terminals-hydration.test.ts
|
||||
- M src/renderer/src/store/slices/terminals.ts
|
||||
|
||||
## Changed Line Ranges (PR Scope)
|
||||
|
||||
| File | Changed Lines |
|
||||
| ---------------------------------------------------------- | -------------------------------------------------------------- |
|
||||
| src/main/persistence.test.ts | 5, 585-796 |
|
||||
| src/main/persistence.ts | 5-15, 58-69, 94-176, 291-298, 329-336 |
|
||||
| src/renderer/src/App.tsx | 31-34, 98, 170-176, 191, 284-291, 294-307, 309-355, 389, 423, 433-437 |
|
||||
| src/renderer/src/lib/workspace-session.test.ts | 1-2, 143-243 |
|
||||
| src/renderer/src/lib/workspace-session.ts | 11-27 |
|
||||
| src/renderer/src/store/slices/terminals-hydration.test.ts | 269-309 |
|
||||
| src/renderer/src/store/slices/terminals.ts | 98-106, 230-233 |
|
||||
|
||||
## Review Standards Reference
|
||||
|
||||
- Follow /review-code standards
|
||||
- Focus on: correctness, security, performance, maintainability
|
||||
- Priority levels: Critical > High > Medium > Low
|
||||
|
||||
## File Categories
|
||||
|
||||
### Electron/Main (Priority 1)
|
||||
- src/main/persistence.ts
|
||||
- src/main/persistence.test.ts
|
||||
|
||||
### Frontend/UI (Priority 3)
|
||||
- src/renderer/src/App.tsx
|
||||
- src/renderer/src/lib/workspace-session.ts
|
||||
- src/renderer/src/lib/workspace-session.test.ts
|
||||
- src/renderer/src/store/slices/terminals.ts
|
||||
- src/renderer/src/store/slices/terminals-hydration.test.ts
|
||||
|
||||
## Skipped Issues (Do Not Re-validate)
|
||||
|
||||
<!-- Issues validated but deemed not worth fixing. Do not re-validate these in future iterations. -->
|
||||
|
||||
- src/main/persistence.ts:144,171 | Low | non-atomic copyFile of .bak.0 — design comment explicitly accepts trade-off ("losing a rolling backup is strictly better than skipping the write")
|
||||
- src/main/persistence.ts:286-298 | Low | rotation runs even when writeGeneration aborts — wasted IO only; addressed by moving rotation after successful write
|
||||
- src/main/persistence.ts:112-123 | Low | statSync on async path — microsecond cost; refactor would expand scope
|
||||
- src/main/persistence.ts:130-147 | Low | rotateBackupsAsync/Sync drift — extracting helper expands scope; close enough
|
||||
- src/main/persistence.test.ts:640-671 | Low | per-slot content assertions — testing improvement, not a defect
|
||||
- src/main/persistence.ts:286-298 | Medium | persistence-boundary hydration gate (architectural) — out of PR scope; renderer gate is sufficient
|
||||
- src/renderer/src/App.tsx:342 | Low | reconnectPersistedTerminals signal not honored today — speculative future-proofing
|
||||
- src/renderer/src/lib/workspace-session.test.ts:162-185 | Low | 10-iteration test trivial — defensive smoke test
|
||||
- src/renderer/src/lib/workspace-session.ts:22-26 | Low | Pick<AppState> structural type coupling — minor style
|
||||
- src/renderer/src/store/slices/terminals.ts:105-106 | Low | setHydrationSucceeded(boolean) accepts false — narrowing API would break test
|
||||
- src/renderer/src/store/slices/terminals-hydration.test.ts:280-286 | Low | "toggles both ways" test — coupled to terminals.ts:105 skip
|
||||
- src/renderer/src/lib/workspace-session.test.ts:144-202 | Low | integration test naming — describes block content
|
||||
- src/renderer/src/store/slices/terminals.ts:98-106 | Low | hydrationSucceeded in TerminalSlice — matches existing convention
|
||||
- src/renderer/src/App.tsx:397-419 | Medium | fallback setState doesn't stash deferredSshSessionIdsByTabId — recovery-of-recovery path; user is in degraded mode and will restart per toast prompt. Acceptable trade-off
|
||||
- src/renderer/src/App.tsx:353-364 | Low | toast lacks explicit id for dedup — single-shot path; speculative future-proofing
|
||||
|
||||
## Iteration State
|
||||
|
||||
Current iteration: 3
|
||||
Last completed phase: Iteration 2 fixes complete (typecheck + tests pass)
|
||||
Files fixed iteration 1:
|
||||
- src/main/persistence.ts (load() backup fallback, chained writes, rotation-after-write, ENOENT handling)
|
||||
- src/main/persistence.test.ts (updated existing tests for new semantics + 6 new tests)
|
||||
- src/renderer/src/App.tsx (gate re-check at fire time, cancelled re-check, reconnect dedup, hydration-fail toast, pending* cleanup, comment fix)
|
||||
Reference in New Issue
Block a user