You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
UI: Switching quickly between users or assets can show the previous one's activity #39653
On the classic feed, open one user's or asset's activity and quickly switch to another one. If the first request answers after the second, the first one's activity replaces the second one's. The page then shows the wrong user's or asset's activity until it is reloaded.
Why
ActivityFeedProvider.tsx has a helper, runActivityRequest, that ignores any response that is not the latest request. Three of its fetchers use it. The other two, fetchEntityActivityHandler and fetchUserActivityHandler (around lines 935–970), set the result directly and skip that check.
Fix
Send both through runActivityRequest.
fetchUserActivityHandler also adds the domain parameter by hand. The domain interceptor already adds it to these requests, so drop the manual one.
Add a unit test with two overlapping requests where the first one resolves last.
The two fetchers do lack the latest-request guard, but no current UI path lets a stale response reach the screen. When the asset changes, the page remounts its ActivityFeedProvider, so a late response for the previous asset lands on a provider that is no longer mounted.
How I checked, on main with a local backend:
Classic mode, dashboard A's Activity tab. A's /activity/entity/... responses were delayed by 5 s, and I navigated in-app to dashboard B.
B's requests answered at about 3.0 s and A's stale ones at about 6.4 s.
B's list stayed correct throughout (B's two events). A's events never appeared.
The proposed fix was dropped from #39733, and #39670 removes the guard along with the dead fetchers that used it. If a flow is ever added that re-fetches different targets on the same mounted provider, the guard belongs in that change, with a test for it.
Activity
Fixes #39653: keep the newest activity when switching assets or users…
harsh-vador commentedon Dec 4, 2026
Closing: this can't be reproduced in the UI.
The two fetchers do lack the latest-request guard, but no current UI path lets a stale response reach the screen. When the asset changes, the page remounts its
ActivityFeedProvider, so a late response for the previous asset lands on a provider that is no longer mounted.How I checked, on
mainwith a local backend:/activity/entity/...responses were delayed by 5 s, and I navigated in-app to dashboard B.The proposed fix was dropped from #39733, and #39670 removes the guard along with the dead fetchers that used it. If a flow is ever added that re-fetches different targets on the same mounted provider, the guard belongs in that change, with a test for it.