Problem
Blank rows appear in the Settings > Agents table after deleting agents. Reported by shawnborton on #95991 (comment) — blank rows showed on a branch build but not on staging, after previously deleting a bunch of agents.
Root cause
The agents table renders one row per sharedNVP_agentPrompt_<accountID> collection key whose matching personalDetailsList[accountID] still exists (AgentsPage.tsx:82-107). A row is only skipped when personal details are missing entirely; if they exist but have an empty displayName/login, the row renders blank.
deleteAgent clears both the prompt key and the personal-details entry on the DELETE_AGENT success response (Agent.ts:289-309), but OPEN_AGENTS_PAGE only merges in what the server returns and never prunes local keys (Agent.ts:23-32). So any orphaned sharedNVP_agentPrompt_* entries left behind by earlier deletes (e.g. deleted offline, or from a build predating current cleanup logic) linger in local Onyx and render as blank rows. Staging looked clean because it had a different/fresher dataset.
Expected behavior
Deleted agents should never leave orphaned sharedNVP_agentPrompt_* entries behind, and the agents table should not render a row for an agent that has no valid personal details (empty name/login).
Reproduction
- Create several agents in Settings > Agents.
- Delete them (ideally reproduce with a delete that doesn't cleanly land the success response, e.g. offline then reconnect).
- Reopen Settings > Agents.
- Observe blank rows in the table.
Possible fixes to explore
- Have
OPEN_AGENTS_PAGE return the full agent set and reset the sharedNVP_agentPrompt collection so stale local keys are pruned, or
- Guard the row builder in
AgentsPage.tsx to skip rows whose personal details have no displayName and no login.
Surfaced from #95991 (comment)
Issue Owner
Current Issue Owner: @NicolasBonet
Problem
Blank rows appear in the Settings > Agents table after deleting agents. Reported by
shawnbortonon #95991 (comment) — blank rows showed on a branch build but not on staging, after previously deleting a bunch of agents.Root cause
The agents table renders one row per
sharedNVP_agentPrompt_<accountID>collection key whose matchingpersonalDetailsList[accountID]still exists (AgentsPage.tsx:82-107). A row is only skipped when personal details are missing entirely; if they exist but have an emptydisplayName/login, the row renders blank.deleteAgentclears both the prompt key and the personal-details entry on theDELETE_AGENTsuccess response (Agent.ts:289-309), butOPEN_AGENTS_PAGEonly merges in what the server returns and never prunes local keys (Agent.ts:23-32). So any orphanedsharedNVP_agentPrompt_*entries left behind by earlier deletes (e.g. deleted offline, or from a build predating current cleanup logic) linger in local Onyx and render as blank rows. Staging looked clean because it had a different/fresher dataset.Expected behavior
Deleted agents should never leave orphaned
sharedNVP_agentPrompt_*entries behind, and the agents table should not render a row for an agent that has no valid personal details (empty name/login).Reproduction
Possible fixes to explore
OPEN_AGENTS_PAGEreturn the full agent set and reset thesharedNVP_agentPromptcollection so stale local keys are pruned, orAgentsPage.tsxto skip rows whose personal details have nodisplayNameand nologin.Surfaced from #95991 (comment)
Issue Owner
Current Issue Owner: @NicolasBonet