mirror of
https://github.com/yattee/yattee.git
synced 2026-10-23 13:12:53 +00:00
The refresh captured its account generation before hopping onto the detached task it runs in. That hop is a suspension point: a context handler running in the gap - the wake-time status flap bumps the generation there - left the request carrying a stale generation. Its completion was then fenced out, and the fenced return deliberately leaves isLoading alone, so nothing current owned the flag: it stayed true, every later refresh skipped itself as already loading, and the retry paths only watch for errors - the feed sat on a spinner nothing would ever finish. The generation and context are now read at dispatch time, so the request that claims isLoading always carries the generation current at that moment and its completion is the one that releases it. The stateless-server poller's terminal writes get the same fence: a stale poller must not hand a newer request's spinner an early ready.