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
[P1/bug] Failed queries with no active connection record as 'Unknown' connection #328
resultStore.doExecuteQuery (src/stores/resultStore.ts:181-219) records history entries even when the connection lookup fails. Line 191: const connectionName = conn?.name ?? "Unknown";.
Problem
When doExecuteQuery is called with a connectionId that doesn't exist in activeConnections (e.g., the connection was dropped between the toolbar click and the IPC, or the user called disconnect mid-execution), the conn lookup returns undefined and the entry is recorded with connectionName: "Unknown". The history then shows entries attributed to a non-existent "Unknown" connection — confusing for users trying to clean up. A user with 50 "Unknown" entries has no way to know which connection they originated from.
Files
src/stores/resultStore.ts:181-219
Expected
A query that fails because the connection was dropped mid-execution does NOT appear in the history panel; the existing successful-query path still records the connection name correctly.
Proposed fix
Scope S — refuse to record history if the connection is gone: add if (!conn) return early in both the catch path AND success path of doExecuteQuery. Failed lookups leave no trace.
Acceptance
A query that fails because the connection was dropped mid-execution does NOT appear in the history panel; the existing successful-query path still records the connection name correctly.
Activity
feat(history): run an entry from the panel, and stop recording phanto…