Skip to content

fix: toast system, streaming SSE, export logs, call-graph regression tests#880

Merged
Gbangbolaoluwagbemiga merged 1 commit into
HyperSafeD:mainfrom
chonilius:fix/issues-857-860-858-852
May 27, 2026
Merged

fix: toast system, streaming SSE, export logs, call-graph regression tests#880
Gbangbolaoluwagbemiga merged 1 commit into
HyperSafeD:mainfrom
chonilius:fix/issues-857-860-858-852

Conversation

@chonilius
Copy link
Copy Markdown

@chonilius chonilius commented May 27, 2026

Closes #857
Closes #852
Closes #860
Closes #858

#857 - Global toast/notification system

  • New ToastProvider in frontend/app/providers/ToastProvider.tsx (~80 LOC, no external deps)
  • useToast() hook exposes toast.success(), toast.error(), toast.info()
  • Top-right stack, max 3 toasts, auto-dismiss 4s, dismissible by click
  • ARIA role=alert + aria-live=assertive

#852 - /terminal EventSource against POST-only /api/analyze

  • New GET /api/analyze/stream?path=... route (frontend/app/api/analyze/stream/route.ts)
  • Spawns sanctifier analyze --format json, forwards each stdout line as SSE data event
  • Event shapes: {type:log}, {type:result,payload}, {type:done}, {type:error}
  • Aborts child process on client disconnect via request.signal
  • /terminal updated to use /api/analyze/stream and parse new event shapes correctly

#860 - Export Logs card is decorative

#858 - CallGraph silently renders empty on shape mismatch

  • frontend/app/dashboard/call-graph.test.ts: unit tests asserting extractCallGraph returns {nodes,edges} (not callGraphNodes/callGraphEdges), arrays are non-empty for auth_gap reports, dashboard memo destructuring uses correct keys
  • e2e/tests/call-graph.spec.ts: Playwright spec uploads fixture JSON and asserts SVG node renders in call-graph viewer

…tests

Issue HyperSafeD#857 - Global toast/notification system:
- New ToastProvider in frontend/app/providers/ToastProvider.tsx
- useToast() hook exposes toast.success(), toast.error(), toast.info()
- Top-right stack, max 3 toasts, auto-dismiss 4s, dismissible by click
- ARIA role=alert + aria-live=assertive for accessibility

Issue HyperSafeD#852 - /terminal EventSource against POST-only /api/analyze:
- New GET /api/analyze/stream?path=... route (frontend/app/api/analyze/stream/route.ts)
- Spawns sanctifier analyze --format json, forwards each line as SSE data event
- Event shapes: {type:log}, {type:result}, {type:done}, {type:error}
- Abort on client disconnect (request.signal)
- /terminal updated to use /api/analyze/stream, parse new event shapes

Issue HyperSafeD#860 - Export Logs card is decorative:
- Replaced static card with actionable Download .log + Copy buttons
- Download serializes logs[] to a .log file via Blob URL
- Copy writes logs to clipboard, shows toast confirmation
- Buttons disabled when logs[] is empty
- Uses useToast() from ToastProvider

Issue HyperSafeD#858 - CallGraph silently renders empty on shape mismatch:
- frontend/app/dashboard/call-graph.test.ts: unit tests asserting extractCallGraph
  returns { nodes, edges } (not callGraphNodes/callGraphEdges), non-empty for
  auth_gap reports, correct dashboard memo destructuring
- e2e/tests/call-graph.spec.ts: Playwright spec uploads fixture JSON and asserts
  SVG node renders in call-graph viewer

Closes HyperSafeD#857, HyperSafeD#852, HyperSafeD#860, HyperSafeD#858
@vercel
Copy link
Copy Markdown

vercel Bot commented May 27, 2026

@Temi-suwa18 is attempting to deploy a commit to the gbangbolaoluwagbemiga's projects Team on Vercel.

A member of the Team first needs to authorize it.

@drips-wave
Copy link
Copy Markdown

drips-wave Bot commented May 27, 2026

@chonilius Great news! 🎉 Based on an automated assessment of this PR, the linked Wave issue(s) no longer count against your application limits.

You can now already apply to more issues while waiting for a review of this PR. Keep up the great work! 🚀

Learn more about application limits

@Gbangbolaoluwagbemiga Gbangbolaoluwagbemiga merged commit 127c24d into HyperSafeD:main May 27, 2026
6 of 17 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment