justinpark commented on PR #44276:
URL: https://github.com/apache/superset/pull/44276#issuecomment-5918604571

   Addressed all review feedback from @sadpandajoe 
   
   1. Hydration race on same-surface dashboard navigation
   Fixed by deriving the routed :idOrSlug directly from 
window.location.pathname (via matchPath, same technique as navigation's own 
page detection) and requiring it to match dashboardInfo.id/slug before treating 
the dashboard as active β€” no extra wiring needed in DashboardPage.tsx.
   
   2. getLayout() returning mutable, Redux-owned state
   Deep-freezes the returned map and every node (meta/children/parents 
included), so a caller mutating a node can't corrupt live layout state outside 
a reducer. Verified safe by auditing every dashboardLayout reducer path β€” all 
replace nodes via spread, never mutate in place.
   
   3. Stale query cache on refreshChart
   Added invalidateChartFormDataCache(chartId), since 
getFormDataWithExtraFilters's per-chart memo only busts on 
filter/color/customization changes, not form_data.
   
   4. refreshChart resolving before the chart finished re-rendering
   Now awaits the chart's Redux status reaching a terminal state 
(rendered/failed/stopped) via store.subscribe, matching its documented contract.
   
   5. updateFilters not validating filterId
   Added the same existence check saveFilters already had β€” an unrecognized ID 
now rejects up front instead of silently scoping to every chart on the das6. 
saveFilters wiping a filter's live valuNow restores the pre-save live dataMask 
vapdate didn't explicitly set a newdefaultDataMask (e.g. a rename no longer 
dter value).7. explore.getQuery()/getChartData() silen chartsChanged the public 
return types from a sinomise<string[]> / Promise<ChartData[]>) β€”one entry per 
query the chart runs (e.g. Mof silently reporting only the first anddropping 
any error the others returned. Anll fails the whole call, since the arrayshape 
can't represent a partial failure.


-- 
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: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to