yousoph opened a new pull request, #40983: URL: https://github.com/apache/superset/pull/40983
## Summary - Fixes [sc-108187](https://app.shortcut.com/preset/story/108187): "Overwrite editor" in Query History does nothing when SqllabBackendPersistence is enabled - Root cause: `restoreSql` passes `query.sqlEditorId` (= `tabViewId`) as the editor ID, but the reducer's `alterUnsavedQueryEditorState` routes it to `alterInArr` looking for an editor with `id === tabViewId` — no match because editors are indexed by client-side ID - Fix: add the same `tabViewId → client-side id` normalization that `START_QUERY` already uses ## Test plan - [ ] New reducer unit test: `QUERY_EDITOR_SET_SQL` with `tabViewId` correctly updates `unsavedQueryEditor.sql` - [ ] Manual: SQL Lab → run a query → type new SQL (don't run) → click pencil icon in Query History → verify editor text replaced ✓ (requires backend persistence enabled) - [ ] Existing test: "should not fail while setting Sql" still passes (non-regression for non-persistence path) 🤖 Generated with [Claude Code](https://claude.com/claude-code) -- 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]
