Skip to content

refactor(site): extract useRuns hook (closes #595)#648

Draft
ronniegeraghty wants to merge 4 commits into
mainfrom
squad/595-extract-useruns-hook
Draft

refactor(site): extract useRuns hook (closes #595)#648
ronniegeraghty wants to merge 4 commits into
mainfrom
squad/595-extract-useruns-hook

Conversation

@ronniegeraghty
Copy link
Copy Markdown
Owner

Summary

Extracts duplicated useEffect fetch pattern from dashboard-page.tsx and prompts-page.tsx into a shared useRuns() custom hook.

Changes

  • Created site/src/app/hooks/useRuns.ts with shared hook
  • Refactored dashboard-page.tsx to use useRuns()
  • Refactored prompts-page.tsx to use useRuns() with proper dependency handling
  • Rebuilt embedded site assets (site/dist/)

Testing

  • ✅ All 18 site test files pass (164 tests)
  • ✅ Go build succeeds with embedded site
  • ✅ No behavior change — cancellation semantics preserved exactly

Closes #595

scribe and others added 4 commits May 22, 2026 21:45
- Morpheus reviewed 32 open issues and identified 3 quick-win recommendations
- Added decision entry to decisions.md with sequencing guidance
- Deleted inbox file (decisions/inbox/morpheus-issue-triage-2026-05-22.md)
- Updated Morpheus history.md with learnings from backlog shape analysis
- Orchestration logs written (not committed; in .gitignore):
  .squad/orchestration-log/2026-05-22T21-44-13Z-morpheus.md
  .squad/log/2026-05-22T21-44-13Z-issue-triage-quick-wins.md

Top 3 quick wins for execution: #644 (enforce evaluation_criteria removal),
#595 (extract useRuns hook), #72 (add early auth check).

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Recorded auth check implementation following the task workflow.
Documents the Waza pattern and auth check placement decision.
Both dashboard-page.tsx and prompts-page.tsx duplicated the same useEffect
fetch pattern with cancellation flag. Extracted to shared useRuns() custom
hook in site/src/app/hooks/useRuns.ts.

Refactored both components to use the hook. No behavior change — cancellation
semantics preserved exactly.

Rebuilt embedded site assets (site/dist/) with changes.

Closes #595

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
@ronniegeraghty ronniegeraghty marked this pull request as draft May 22, 2026 23:41
ronniegeraghty pushed a commit that referenced this pull request May 22, 2026
- Add orchestration logs for Neo (3 tasks) and Trinity (Issue #595)
- Add session log summarizing PRs #647, #648, #649, and follow-up #650
- Document autonomous two-PR split decision for Issue #644
- Decisions.md updated with scope management rationale (Phase 1 deprecation
  warning + Phase 2 migration tracked separately)

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
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.

Extract useRuns hook for dashboard/prompts pages

1 participant