Self-hosted, Self-Improving, Federated Everything App — dev management, agent orchestration, persistent mind, digital twin, second brain, and creative pipeline from a single dashboard over Tailscale to port the user into the OS
JavaScript ai-agentsdashboarddeveloper-toolsdigital-twinquantified-selfsecond-brainself-hostedtailscale
fix([issue-2567]): silence double error toasts in Settings tabs and JIRA page
[._.]/ Adam Eivyf03ac95da0a0
diff --git a/.changelog/NEXT.md b/.changelog/NEXT.mdindex 055b74d4e7..19d5467bf0 100644--- a/.changelog/NEXT.md+++ b/.changelog/NEXT.md@@ -45,7 +45,7 @@## Fixed-- **Deleting a blocked CoS task now clears the "N blocked tasks" alert bar immediately.** On the Chief of Staff → Tasks page, the `ActionableInsightsBanner` (which owns its own `/cos/actionable-insights` fetch, decoupled from the task list) kept showing a stale blocked-tasks alert after a blocked task was deleted, until its 60s poll fired or the user manually dismissed it. The page now bumps an `insightsRefreshKey` on every task-list mutation, which the banner watches (via a mount-skipping effect) to `refetch()` its server-derived insights — so a delete (or any task mutation through the tasks list) re-derives the banner right away. Follow-up #2654 tracks lifting the insights fetch into the page's `fetchData` to also cover socket/health-driven staleness.+- **[issue-2567] Stop double error toasts across the Settings tabs and the JIRA integration page.** Several Settings surfaces routed a request through the auto-toasting `request()` helper AND showed their own `toast.error` in a custom catch, so a failure stacked two toasts. Every such call now passes `{ silent: true }` so the caller's catch is the single error layer — covering VoiceTab (config load/save, Piper voice download), ImageGenTab (settings/tools load, save, tool register/update, test render), TelegramTab (settings load, method/config/test/disconnect, forward-types), BackupTab (settings load + save), DatabaseTab (status load), EmbeddingsTab (save), MortalLoomTab and CaptionModelPicker (save), and the JIRA instances page (load/save/delete/test — mirroring the DataDog fix from #2520). Loaders and callers without a custom toast are unchanged (single default-helper layer preserved). The `getVoiceConfig`/`updateVoiceConfig`/`fetchPiperVoice`, telegram, `registerTool`/`updateTool`/`getToolsList`, and `getDatabaseStatus` wrappers gained a backward-compatible trailing `options` param so callers can opt into silent. Follow-up sweep of the remaining pipeline/writers-room/universe/media/etc. areas is tracked in #2669. On the Chief of Staff → Tasks page, the `ActionableInsightsBanner` (which owns its own `/cos/actionable-insights` fetch, decoupled from the task list) kept showing a stale blocked-tasks alert after a blocked task was deleted, until its 60s poll fired or the user manually dismissed it. The page now bumps an `insightsRefreshKey` on every task-list mutation, which the banner watches (via a mount-skipping effect) to `refetch()` its server-derived insights — so a delete (or any task mutation through the tasks list) re-derives the banner right away. Follow-up #2654 tracks lifting the insights fetch into the page's `fetchData` to also cover socket/health-driven staleness.- **claim-issue no longer reports "no open issues" when an author filter is hiding a full queue.** The perpetual `claim-issue` / `claim-issue-gitlab` work-detector runs `gh`/`glab issue list` with an author filter (`self`→`@me`, or `owner`→the repo owner), and an empty *filtered* result was flattened to the reason `no-open-issues` — so a repo with open issues that simply don't match the filter parked for a full recheck cadence claiming there was nothing to do. The two failure modes this hid: `owner` resolves to an **org** (e.g. a GHE repo owned by a team), which is never an issue author, so the filter matches nothing; and `self`/`@me` is the wrong identity when the forge session differs from whoever filed the issues. The detector now re-probes without the author filter when the filtered list is empty, and if open issues exist it parks with a new `no-authored-issues` reason carrying the real open count. The on-demand "Run" toast now says *"open issues exist, but none match the author filter — set it to \"any\" (0 of N open)"* instead of the misleading "no open issues", pointing the user at the fix. A genuinely empty repo still reports `no-open-issues`, and the `any` filter is unaffected (no wasted re-probe). New private helper `countOpenIssuesUnfiltered`; covered by `perpetualWork.test.js` and `useOnDemandTaskToast.test.jsx`.- **claim-issue distinguishes the "owner filter matches an org" trap from a personal-username mismatch.** Building on the fix above: when the `owner` author filter resolves to an **organization** login (the common case for team/enterprise repos), `--author <org>` can only ever match zero issues — an org is never an issue author. The detector now recognizes an org owner up front (`gh repo view --json owner,isInOrganization`), skips the guaranteed-empty query entirely, and parks with a distinct `owner-is-org` reason carrying the real open count. The toast now reads *"the \"owner\" filter matches an org, which can't author issues — set it to \"self\" or \"any\" (0 of N open)"* instead of the generic "set it to any", so the user isn't left thinking their own username is mismatched. `owner` mode on a user-owned repo is unchanged. Covered by `perpetualWork.test.js` and `useOnDemandTaskToast.test.jsx`.diff --git a/client/src/components/loraTraining/CaptionModelPicker.jsx b/client/src/components/loraTraining/CaptionModelPicker.jsxindex 74ec394e51..8999f4330a 100644--- a/client/src/components/loraTraining/CaptionModelPicker.jsx+++ b/client/src/components/loraTraining/CaptionModelPicker.jsx@@ -64,7 +64,7 @@ export default function CaptionModelPicker({ onChange }) {captionModel: picked ? picked.id : null,};try {- await updateSettings({ loraTraining: nextLoraTraining });+ await updateSettings({ loraTraining: nextLoraTraining }, { silent: true });loraTrainingRef.current = nextLoraTraining;} catch {toast.error('Could not save caption-model preference');diff --git a/client/src/components/settings/BackupTab.jsx b/client/src/components/settings/BackupTab.jsxindex 2317dd62d9..6457060504 100644--- a/client/src/components/settings/BackupTab.jsx+++ b/client/src/components/settings/BackupTab.jsx@@ -60,7 +60,7 @@ export function BackupTab() {useEffect(() => {Promise.all([- getSettings(),+ getSettings({ silent: true }),getBackupStatus({ silent: true }).catch(() => null),getBackupSnapshots({ silent: true }).catch(() => []),])@@ -89,7 +89,7 @@ export function BackupTab() {const handleSave = async () => {setSaving(true);try {- await updateSettings({ backup: { destPath, enabled, cronExpression, excludePaths, disabledDefaultExcludes } });+ await updateSettings({ backup: { destPath, enabled, cronExpression, excludePaths, disabledDefaultExcludes } }, { silent: true });setSavedDestPath(destPath);setSavedExcludePaths(excludePaths);setSavedDisabledDefaultExcludes(disabledDefaultExcludes);diff --git a/client/src/components/settings/BackupTab.test.jsx b/client/src/components/settings/BackupTab.test.jsxindex 6cebf51a01..40e82406c6 100644--- a/client/src/components/settings/BackupTab.test.jsx+++ b/client/src/components/settings/BackupTab.test.jsx@@ -73,7 +73,7 @@ describe('BackupTab', () => {excludePaths: [],disabledDefaultExcludes: [],},- });+ }, { silent: true });expect(toast.success).toHaveBeenCalledWith('Settings saved');});diff --git a/client/src/components/settings/DatabaseTab.jsx b/client/src/components/settings/DatabaseTab.jsxindex 0cc2eb837e..be57a760a3 100644--- a/client/src/components/settings/DatabaseTab.jsx+++ b/client/src/components/settings/DatabaseTab.jsx@@ -188,7 +188,7 @@ export function DatabaseTab() {const loadStatus = useCallback(() => {setDbLoading(true);- getDatabaseStatus()+ getDatabaseStatus({ silent: true }).then(setDbStatus).catch(() => toast.error('Failed to load database status')).finally(() => setDbLoading(false));diff --git a/client/src/components/settings/EmbeddingsTab.jsx b/client/src/components/settings/EmbeddingsTab.jsxindex 79c1e18d37..4612a43502 100644--- a/client/src/components/settings/EmbeddingsTab.jsx+++ b/client/src/components/settings/EmbeddingsTab.jsx@@ -76,7 +76,7 @@ export default function EmbeddingsTab() {setSaving(true);await updateSettings({embeddings: { provider, model: model.trim() || null },- }).then(() => {+ }, { silent: true }).then(() => {setSaved({ provider, model: model.trim() || '' });toast.success('Embeddings settings saved');}).catch((err) => {diff --git a/client/src/components/settings/ImageGenTab.jsx b/client/src/components/settings/ImageGenTab.jsxindex cce9a5fc39..265a1c4a30 100644--- a/client/src/components/settings/ImageGenTab.jsx+++ b/client/src/components/settings/ImageGenTab.jsx@@ -176,7 +176,7 @@ export function ImageGenTab() {useEffect(() => () => closeRenderSse(), [closeRenderSse]);useEffect(() => {- Promise.all([getSettings(), getToolsList()])+ Promise.all([getSettings({ silent: true }), getToolsList({ silent: true })]).then(([s, tools]) => {const ig = s?.imageGen || {};const m = ig.mode || IMAGE_GEN_MODE.EXTERNAL;@@ -268,7 +268,7 @@ export function ImageGenTab() {},};try {- await updateSettings(patch);+ await updateSettings(patch, { silent: true });// Store trimmed values to match what was persisted — otherwise// trailing whitespace in the inputs leaves isDirty stuck true even// after a successful save (state has " codex " but `saved` was@@ -316,11 +316,11 @@ export function ImageGenTab() {const syncTool = async ({ id, registered, data, shouldCreate, onCreated, errLabel }) => {if (registered) {- return updateTool(id, data).catch((err) => toast.error(err.message || `Failed to update ${errLabel}`));+ return updateTool(id, data, { silent: true }).catch((err) => toast.error(err.message || `Failed to update ${errLabel}`));}if (shouldCreate) {try {- await registerTool({ id, ...data });+ await registerTool({ id, ...data }, { silent: true });onCreated?.();} catch (err) {toast.error(err.message || `Failed to register ${errLabel}`);@@ -355,7 +355,7 @@ export function ImageGenTab() {// with unsaved changes, but reading from `saved` makes the contract// explicit. Codex is async like local (returns a job descriptor// immediately) so the SSE branch handles it.- const result = await generateImage({ prompt: testPrompt.trim(), mode: saved.mode });+ const result = await generateImage({ prompt: testPrompt.trim(), mode: saved.mode }, { silent: true });// Local + Codex modes return immediately after spawning the child —// the PNG isn't on disk yet. Subscribe to the per-job SSE and only// mark the render complete on the `complete` event (or fail ondiff --git a/client/src/components/settings/MortalLoomTab.jsx b/client/src/components/settings/MortalLoomTab.jsxindex 9320a08bda..94f11259a0 100644--- a/client/src/components/settings/MortalLoomTab.jsx+++ b/client/src/components/settings/MortalLoomTab.jsx@@ -47,7 +47,7 @@ export function MortalLoomTab() {path: path.trim(),lastImportAt: lastImport}- });+ }, { silent: true });toast.success('MortalLoom settings saved');await refreshStatus();} catch (err) {diff --git a/client/src/components/settings/TelegramTab.jsx b/client/src/components/settings/TelegramTab.jsxindex b8ac5404d4..8738b61739 100644--- a/client/src/components/settings/TelegramTab.jsx+++ b/client/src/components/settings/TelegramTab.jsx@@ -35,7 +35,7 @@ export function TelegramTab() {useEffect(() => {Promise.all([- getSettings(),+ getSettings({ silent: true }),getTelegramStatus().catch(() => null)]).then(([settings, status]) => {if (status) {@@ -51,7 +51,7 @@ export function TelegramTab() {const handleMethodChange = async (newMethod) => {setSwitching(true);try {- const status = await updateTelegramMethod(newMethod);+ const status = await updateTelegramMethod(newMethod, { silent: true });setMethod(newMethod);setTgStatus(status);toast.success(newMethod === 'mcp-bridge'@@ -71,7 +71,7 @@ export function TelegramTab() {}setTgSaving(true);try {- const status = await updateTelegramConfig({ token: tgToken, chatId: tgChatId });+ const status = await updateTelegramConfig({ token: tgToken, chatId: tgChatId }, { silent: true });setTgStatus(status);toast.success(tgChatId? 'Telegram connected — check your chat for a test message'@@ -86,7 +86,7 @@ export function TelegramTab() {const handleTelegramTest = async () => {setTgTesting(true);try {- await testTelegram();+ await testTelegram(undefined, { silent: true });toast.success('Test message sent');} catch (err) {toast.error(err.message || 'Failed to send test message');@@ -98,7 +98,7 @@ export function TelegramTab() {const handleTelegramDisconnect = async () => {setTgDisconnecting(true);try {- await deleteTelegramConfig();+ await deleteTelegramConfig({ silent: true });setTgStatus(null);setTgToken('');setTgChatId('');@@ -116,7 +116,7 @@ export function TelegramTab() {? tgForwardTypes.filter(t => t !== type): [...tgForwardTypes, type];setTgForwardTypes(updated);- updateTelegramForwardTypes(updated).catch(() => toast.error('Failed to update forward types'));+ updateTelegramForwardTypes(updated, { silent: true }).catch(() => toast.error('Failed to update forward types'));};if (loading) {diff --git a/client/src/components/settings/VoiceTab.jsx b/client/src/components/settings/VoiceTab.jsxindex e0cb706213..14bbb1144c 100644--- a/client/src/components/settings/VoiceTab.jsx+++ b/client/src/components/settings/VoiceTab.jsx@@ -124,7 +124,7 @@ export function VoiceTab() {}, [currentEngine]);useEffect(() => {- Promise.all([getVoiceConfig(), getVoiceStatus()])+ Promise.all([getVoiceConfig({ silent: true }), getVoiceStatus({ silent: true })]).then(([config, s]) => { setCfg(config); setStatus(s); }).catch(() => toast.error('Failed to load voice settings')).finally(() => setLoading(false));@@ -180,7 +180,7 @@ export function VoiceTab() {const handleSave = async () => {setSaving(true);try {- const r = await updateVoiceConfig(cfg);+ const r = await updateVoiceConfig(cfg, { silent: true });setCfg(r.config);const rec = r.reconciliation || {};if (rec.error) {@@ -394,7 +394,7 @@ export function VoiceTab() {// preview button while a download is in flight.if (v && v.downloaded === false) {setDownloadingVoice(val);- fetchPiperVoice(val)+ fetchPiperVoice(val, { silent: true }).then(() => listVoices('piper')).then((fresh) => setVoiceList(fresh)).catch((err) => toast.error(`Voice download failed: ${err.message}`))diff --git a/client/src/pages/Jira.jsx b/client/src/pages/Jira.jsxindex b0d3f0a3a0..1ae22a24a9 100644--- a/client/src/pages/Jira.jsx+++ b/client/src/pages/Jira.jsx@@ -43,7 +43,7 @@ export default function Jira() {const loadInstances = async () => {try {setLoading(true);- const response = await api.get('/jira/instances');+ const response = await api.get('/jira/instances', { silent: true });setInstances(response.instances || {});} catch (error) {console.error(`❌ Failed to load JIRA instances: ${error.message}`);@@ -105,7 +105,7 @@ export default function Jira() {apiToken: formData.apiToken};- const saved = await api.post('/jira/instances', payload);+ const saved = await api.post('/jira/instances', payload, { silent: true });toast.success(`JIRA instance "${payload.name}" saved successfully`);setInstances(prev => ({ ...prev, [saved.id]: saved }));@@ -128,7 +128,7 @@ export default function Jira() {setDeleteConfirm(null);try {- await api.delete(`/jira/instances/${instanceId}`);+ await api.delete(`/jira/instances/${instanceId}`, { silent: true });toast.success(`JIRA instance "${instanceId}" deleted`);setInstances(prev => {const next = { ...prev };@@ -150,7 +150,7 @@ export default function Jira() {setTestingInstance(instanceId);setTestResult(null);- const response = await api.post(`/jira/instances/${instanceId}/test`);+ const response = await api.post(`/jira/instances/${instanceId}/test`, undefined, { silent: true });setTestResult(response);if (response.success) {diff --git a/client/src/services/apiDatabase.js b/client/src/services/apiDatabase.jsindex c6bba44a31..dca1fb5ac0 100644--- a/client/src/services/apiDatabase.js+++ b/client/src/services/apiDatabase.js@@ -1,7 +1,7 @@import { request } from './apiCore.js';// Database-export const getDatabaseStatus = () => request('/database/status');+export const getDatabaseStatus = (options) => request('/database/status', options);export const switchDatabase = (target, migrate = false) => request('/database/switch', {method: 'POST',body: JSON.stringify({ target, migrate })diff --git a/client/src/services/apiSystem.js b/client/src/services/apiSystem.jsindex b00f045ad5..1b62786f8d 100644--- a/client/src/services/apiSystem.js+++ b/client/src/services/apiSystem.js@@ -137,22 +137,26 @@ export const clearNotifications = () => request('/notifications', { method: 'DEL// Telegramexport const getTelegramStatus = () => request('/telegram/status');-export const updateTelegramConfig = (data) => request('/telegram/config', {+export const updateTelegramConfig = (data, options) => request('/telegram/config', {method: 'PUT',- body: JSON.stringify(data)+ body: JSON.stringify(data),+ ...options});-export const deleteTelegramConfig = () => request('/telegram/config', { method: 'DELETE' });-export const testTelegram = (message) => request('/telegram/test', {+export const deleteTelegramConfig = (options) => request('/telegram/config', { method: 'DELETE', ...options });+export const testTelegram = (message, options) => request('/telegram/test', {method: 'POST',- body: JSON.stringify({ message })+ body: JSON.stringify({ message }),+ ...options});-export const updateTelegramForwardTypes = (forwardTypes) => request('/telegram/forward-types', {+export const updateTelegramForwardTypes = (forwardTypes, options) => request('/telegram/forward-types', {method: 'PUT',- body: JSON.stringify({ forwardTypes })+ body: JSON.stringify({ forwardTypes }),+ ...options});-export const updateTelegramMethod = (method) => request('/telegram/method', {+export const updateTelegramMethod = (method, options) => request('/telegram/method', {method: 'PUT',- body: JSON.stringify({ method })+ body: JSON.stringify({ method }),+ ...options});export const reloadTelegramBridge = () => request('/telegram/bridge/reload', { method: 'POST' });@@ -234,15 +238,17 @@ export const uploadGalleryImage = (base64Data, options = {}) => request('/image-});// Tools Registry-export const getToolsList = () => request('/tools');+export const getToolsList = (options) => request('/tools', options);export const getEnabledTools = () => request('/tools/enabled');-export const registerTool = (data) => request('/tools', {+export const registerTool = (data, options) => request('/tools', {method: 'POST',- body: JSON.stringify(data)+ body: JSON.stringify(data),+ ...options});-export const updateTool = (id, data) => request(`/tools/${id}`, {+export const updateTool = (id, data, options) => request(`/tools/${id}`, {method: 'PUT',- body: JSON.stringify(data)+ body: JSON.stringify(data),+ ...options});export const deleteTool = (id) => request(`/tools/${id}`, { method: 'DELETE' });diff --git a/client/src/services/apiVoice.js b/client/src/services/apiVoice.jsindex 498d94cb48..6e70be7b29 100644--- a/client/src/services/apiVoice.js+++ b/client/src/services/apiVoice.js@@ -5,10 +5,10 @@ import api from './apiCore';// useAsyncAction). Without it the user sees a stacked toast for every// failure — and the Memory Management panel polls every 5s.export const getVoiceStatus = (options) => api.get('/voice/status', options);-export const getVoiceConfig = () => api.get('/voice/config');-export const updateVoiceConfig = (patch) => api.put('/voice/config', patch);-export const listVoices = (engine) => api.get(`/voice/voices${engine ? `?engine=${engine}` : ''}`);-export const fetchPiperVoice = (voice) => api.post('/voice/piper/fetch', { voice });+export const getVoiceConfig = (options) => api.get('/voice/config', options);+export const updateVoiceConfig = (patch, options) => api.put('/voice/config', patch, options);+export const listVoices = (engine, options) => api.get(`/voice/voices${engine ? `?engine=${engine}` : ''}`, options);+export const fetchPiperVoice = (voice, options) => api.post('/voice/piper/fetch', { voice }, options);// Returns the raw WAV bytes of the test utterance. Optional `voice` and// `engine` overrides let the voice-picker preview audition a voice from a