Skip to content

fix(ui): make PR/push backend calls non-blocking for immediate UI feedback#411

Merged
matt2e merged 1 commit intomainfrom
pause-making-a-pr
Mar 19, 2026
Merged

fix(ui): make PR/push backend calls non-blocking for immediate UI feedback#411
matt2e merged 1 commit intomainfrom
pause-making-a-pr

Conversation

@matt2e
Copy link
Contributor

@matt2e matt2e commented Mar 19, 2026

Summary

  • Converts handleCreatePr and handlePush from async/await to fire-and-forget .then()/.catch() chains so the UI updates immediately without blocking on the backend response
  • Adds .catch() to openUrl call to prevent unhandled promise rejection

Test plan

  • Verify PR creation button responds immediately without waiting for backend
  • Verify push button responds immediately without waiting for backend
  • Verify error states still display correctly on failure
  • Verify clicking a created PR URL still opens correctly

🤖 Generated with Claude Code

…dback

Convert handleCreatePr and handlePush from async/await to .then()/.catch()
so the functions return synchronously after setting the "creating"/"pushing"
UI state. This ensures Svelte flushes reactivity and the browser repaints
the spinner immediately, preventing the UI freeze that could occur when the
backend call blocked the function from returning.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
@matt2e matt2e requested review from baxen and wesbillman as code owners March 19, 2026 00:23
@matt2e matt2e merged commit fb3170c into main Mar 19, 2026
4 checks passed
@matt2e matt2e deleted the pause-making-a-pr branch March 19, 2026 04:36
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