Repository navigation
robust async state machine for the milestones board (loading/empty/error/success) #1099
Copy link
Copy link
Closed
Labels
GRANTFOX OSSGrantFox open-source campaign taskGrantFox open-source campaign taskMAYBE REWARDEDMay be rewarded under the GrantFox campaignMay be rewarded under the GrantFox campaignOfficial Campaign | FWC26GrantFox FWC26 official campaignGrantFox FWC26 official campaignTHIRD CAMPAIGNarea:milestonesmilestonesmilestonespriority:mediumMedium priorityMedium prioritystack:nextjsNext.jsNext.jsstack:reactReactReactstack:typescriptTypeScriptTypeScripttype:featureNew functionalityNew functionality
Description
Summary
The milestones board conflates loading, empty, error, and success, so users sometimes see a blank screen or an error behind data. Model the fetch as an explicit state machine with mutually-exclusive states and a retry.
Why this matters
Ambiguous async states are a top source of confusing UIs and bugs. An explicit machine makes every state intentional and testable.
Requirements
- Model the milestones board fetch as
loading | empty | error | success, mutually exclusive by construction. - Render the correct UI for each, with a retry affordance on error.
- Transitions are deterministic; no state can render behind another.
- Announce state changes to assistive tech.
Technical guidance
- Represent state as one discriminated union, not separate booleans.
- Reset to loading on an explicit refetch.
Edge cases — each must have a test
- loading -> shows loader only
- empty result -> empty state only
- error -> error + retry only
- success -> content only
- retry -> returns to loading then resolves
Acceptance criteria
- All requirements and every edge case above implemented and covered by tests
- New unit and integration tests; existing tests still pass and no regressions
- Structured, typed errors (no leaked internals; stable codes)
-
npm run lint,npm test, andnpm run buildall pass locally - Code follows the repo's existing conventions; no duplication or dead code
- Short docs/comments explaining the design and any non-obvious decisions
- PR description explains the approach and includes
Closes #<issue>
Out of scope
- Global fetch cache
- Suspense migration
Rewards
Part of the GrantFox OSS / Official Campaign (FWC26) — this task may be rewarded. PR quality is assessed by AI: depth, correctness under edge cases, meaningful tests, and clean design are what earn the reward. Shallow changes (typos, formatting, trivial docs) do not qualify.
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
GRANTFOX OSSGrantFox open-source campaign taskGrantFox open-source campaign taskMAYBE REWARDEDMay be rewarded under the GrantFox campaignMay be rewarded under the GrantFox campaignOfficial Campaign | FWC26GrantFox FWC26 official campaignGrantFox FWC26 official campaignTHIRD CAMPAIGNarea:milestonesmilestonesmilestonespriority:mediumMedium priorityMedium prioritystack:nextjsNext.jsNext.jsstack:reactReactReactstack:typescriptTypeScriptTypeScripttype:featureNew functionalityNew functionality
Activity
Agencybuilds commentedon Aug 25, 2026
I’m interested in working on this issue. I can investigate the current behavior, make the required changes, and test the implementation to ensure the issue is properly resolved.
Iker2522 commentedon Sep 5, 2026
I'd like to take this issue on!
I can refactor the milestones board fetch state to use an explicit discriminated union (loading | empty | error | success) to eliminate ambiguous async states and ghost overlays.
I will build the state machine so transitions are mutually exclusive by construction, wire a retry affordance that explicitly resets to loading, mask internal error leakage behind structured error codes, and add ARIA live region announcements for screen readers.
I will also write comprehensive unit and integration tests for every state and transition path, provide short documentation explaining the design, and ensure npm run lint, npm test, and npm run build all pass cleanly. PR ready in 1 day. Closes #.
Okorie2000-code commentedon Sep 9, 2026
Hi Maintainer, I'd like to work on this issue and can start right away. Please assign it to me.
guptakumarranjeet150 commentedon Sep 9, 2026
Hi maintainers,
I would love to take this on. My planned approach:
robust async state machine for the milestones board (loading/empty/error/success)with explicitrequire_authchecks, clean storage layouts, and robust Soroban contract logic.Looking forward to contributing—please feel free to assign!
Chidi-Dev1 commentedon Sep 11, 2026
I’d love the opportunity to resolve this issue. Kindly assign it to me.
shobhamerabacha-star commentedon Sep 12, 2026
Hi everyone,
I would love to take this on. My planned approach:
robust async state machine for the milestones board (loading/empty/error/success)with explicitrequire_authchecks, clean storage layouts, and robust Soroban contract logic.Happy to pick this up today—please assign to me!
ranjeet150 commentedon Sep 13, 2026
Hey team,
I would like to resolve this issue. Here is my proposed execution plan:
robust async state machine for the milestones board (loading/empty/error/success)with explicitrequire_authchecks, clean storage layouts, and robust Soroban contract logic.Happy to pick this up today—please assign to me!