You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@superset.apache.org by "rusackas (via GitHub)" <gi...@apache.org> on 2026/06/04 19:49:39 UTC
Re: [PR] fix(dashboard): prevent stale favorite status errors after navigation [superset]
rusackas commented on PR #38156:
URL: https://github.com/apache/superset/pull/38156#issuecomment-4625570342
@aminghadersohi great catch on `savePublished` — you're right, it had the exact same race condition this PR fixes for the favorite-star thunks. Its `.then()`/`.catch()` dispatched the success/error toasts and `togglePublished` with no `currentId === id` guard, so publishing and navigating away before the PUT resolved would surface "This dashboard is now published" on the wrong dashboard.
Fixed in 979ed16df0: threaded `getState` through `savePublishedThunk` and gated every dispatch on the dashboard ID still being current, mirroring `fetchFaveStar`/`saveFaveStar`. Also added a `savePublished race condition` test block covering all four branches (success/error × id-matches/id-changed). Thanks for the review!
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org