#17410 · @BYK · opened Mar 13, 2026 at 6:44 PM UTC · last updated Mar 21, 2026 at 10:24 AM UTC
fix(app): defer provider and agent fetches from blocking bootstrap
Score breakdown
Impact
Clarity
Urgency
Ease Of Review
Guidelines
Readiness
Size
Trust
Traction
Summary
This PR optimizes the application's initial load time by making provider and agent data fetches non-blocking during bootstrap. This allows the UI to render faster, improving user experience. The change is small, focusing on deferring these requests.
Description
Issue for this PR
Closes #17408
Type of change
- [ ] Bug fix
- [ ] New feature
- [x] Refactor / code improvement
- [ ] Documentation
What does this PR do?
During global sync bootstrap, the provider list, provider auth, and agent list fetches are all marked as blocking requests. The UI cannot render until all three complete. However, provider and agent data are not needed for the initial render — the session list and message timeline are what the user sees first.
This PR moves the provider and agent fetches out of the blockingRequests object and into fire-and-forget calls that populate the store asynchronously. The UI now renders as soon as sessions are loaded, with provider/agent data appearing when their respective API calls complete.
The change is a one-file, 4-insertion/5-deletion diff in bootstrap.ts.
How did you verify your code works?
- Tested locally — UI renders faster, provider/agent dropdowns populate shortly after
- No regressions in session list or message rendering
Screenshots / recordings
N/A — logic change in bootstrap flow.
Checklist
- [x] I have tested my changes locally
- [x] I have not included unrelated changes in this PR
Linked Issues
#17408 Slow initial load — provider and agent fetches block bootstrap
View issueComments
No comments.
Changed Files
packages/app/src/components/dialog-connect-provider.tsx
+1−1packages/app/src/components/dialog-custom-provider.tsx
+1−1packages/app/src/context/global-sync/bootstrap.ts
+4−5packages/opencode/src/cli/cmd/tui/component/dialog-provider.tsx
+1−1