Skip to content

Bind the frontend error-state retry callback - #638

Merged
addyosmani merged 1 commit into
addyosmani:mainfrom
rudycelekli:fix/frontend-retry-20261003
Oct 10, 2026
Merged

addyosmani merged 1 commit into
addyosmani:mainfrom
rudycelekli:fix/frontend-retry-20261003

Conversation

@rudycelekli

Copy link
Copy Markdown
Contributor

Problem and change

TaskListContainer passes refetch into ErrorState, but never binds it from useTasks(). The error path throws a ReferenceError while rendering, so the retry UI cannot appear.

Bind the callback alongside the existing hook result fields. The loading, empty and populated branches stay unchanged.

Reproduction and controls

I extracted and transpiled the exact container example and mounted it with React 19.2.0, ReactDOM 19.2.0 and jsdom. The custom hook and presentation components were supplied at their existing boundaries; the hook returns the fields shown in the example plus its retry callback.

Before: the error-state control fails with refetch is not defined; the other three branches pass. After: all four pass, and clicking retry calls the hook callback exactly once. Reverting the binding reproduces the failure.

This is a DOM runtime check, not a browser-engine or paid model behavior evaluation. No runtime dependency was added upstream.

Repository gates

Node 24.19.0 on macOS: all existing 173 tests passed with no skips; all five validators passed; routing passed 141 checks with 89/89 rank-one positives at the unchanged 95% floor. Bash cache and ignore controls and the session-start payload passed. The description and trigger cases are unchanged, and the rejection ledger has no prior entry for this example. No open PR touches this skill.

Linux/Windows and plugin-install checks are left to hosted CI; they are not claimed as locally run. Existing PRs from this contributor currently require maintainer workflow approval.

AI assistance: OpenAI Codex / GPT-6 was used for investigation and the patch.

Signed-off-by: Rudy Celekli <47457359+rudycelekli@users.noreply.github.com>

@addyosmani addyosmani left a comment

Copy link
Copy Markdown
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

praise: right, refetch was never defined in the sample, so the error branch threw a ReferenceError. One identifier, correct fix. Merging.

@addyosmani
addyosmani merged commit 446e75c into addyosmani:main Oct 10, 2026
7 checks passed
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.

2 participants