stablyai/orca · warning
sending diagnostics is disabled
Error message
sending diagnostics is disabled
What it means
First of two consent re-checks in the `diagnostics:uploadBundle` IPC handler, fired before the native confirmation dialog. Main re-reads `getDiagnosticsStatus()` because the renderer is in the threat model and the user may have toggled the Privacy setting off in the window between collect and upload. Throwing here guarantees consent is current at the moment of upload.
Source
Thrown at src/main/ipc/diagnostics.ts:253
orcaChannel: resolveDiagnosticOrcaChannel(),
...(lookbackMinutes !== undefined ? { lookbackMinutes } : {})
})
rememberBundle(bundle)
return toBundlePreview(bundle)
}
)
ipcMain.handle(
'diagnostics:uploadBundle',
async (_event, bundleSubmissionId: unknown): Promise<UploadBundleIpcResult> => {
// Why: the renderer is in the threat model. Upload only a payload main
// collected and retained for preview, never renderer-supplied bytes.
const pendingForConfirmation = getPendingBundleForUpload(bundleSubmissionId)
// Consent gate: main is the consent enforcement boundary; the
// renderer-side button-hide is UX, not security. Re-check here in case
// the user toggled the setting off between collect and upload.
if (!getDiagnosticsStatus().bundleEnabled) {
throw new Error('sending diagnostics is disabled')
}
const confirmed = await confirmBundleUpload(pendingForConfirmation.bundle)
if (!confirmed) {
return { canceled: true }
}
// Why: the preview can be discarded or diagnostics can be disabled
// while the native confirmation dialog is open.
const { bundle, payload } = getPendingBundleForUpload(bundleSubmissionId)
if (!getDiagnosticsStatus().bundleEnabled) {
throw new Error('sending diagnostics is disabled')
}
const tokenEndpoint = resolveDiagnosticTokenEndpoint()
if (!tokenEndpoint) {
throw new Error('sending diagnostics is not configured for this build')
}
const result = await uploadDiagnosticBundle({
tokenEndpoint,
payload,View on GitHub (pinned to 1136503c6a)
Solutions
- Before calling upload, re-check `diagnostics:getStatus` and abort the upload flow if `bundleEnabled` is false.
- If the user meant to upload, re-enable diagnostic-bundle collection in Settings -> Privacy, then collect a fresh bundle and upload it.
- Have the renderer treat a disabled status as a hard stop and discard any retained preview it holds.
Example fix
// before
await ipcRenderer.invoke('diagnostics:uploadBundle', submissionId)
// after
const status = await ipcRenderer.invoke('diagnostics:getStatus')
if (!status.bundleEnabled) {
// consent revoked since collect; abort and tell the user
return
}
await ipcRenderer.invoke('diagnostics:uploadBundle', submissionId) Defensive patterns
Strategy: validation
Validate before calling
// Re-check consent right before upload; it may have changed since collect.
const status = await ipcRenderer.invoke('diagnostics:getStatus')
if (!status.bundleEnabled) {
// consent revoked since collect; abort the upload flow
return
}
await ipcRenderer.invoke('diagnostics:uploadBundle', submissionId) Type guard
function bundleStillEnabled(s: unknown): boolean {
return typeof s === 'object' && s !== null && (s as any).bundleEnabled === true
} Try / catch
try {
await ipcRenderer.invoke('diagnostics:uploadBundle', submissionId)
} catch (e) {
if (e instanceof Error && e.message === 'sending diagnostics is disabled') {
showConsentRevokedNotice()
return
}
throw e
} Prevention
- Never assume consent held at collect time still holds at upload time.
- Re-read status synchronously before each consent-gated network action.
- Discard retained preview handles when consent flips off, to avoid retrying a now-forbidden upload.
When it happens
Trigger: Calling `ipcRenderer.invoke('diagnostics:uploadBundle', bundleSubmissionId)` after the user disabled bundle collection in Settings -> Privacy sometime after the bundle was collected but before upload began.
Common situations: User collected a bundle, changed their mind in Privacy settings, then clicked upload; automated flow that collected then waited while the setting was flipped; long pause between collect and upload during which consent was revoked.
Related errors
- creating review files is disabled
- review file has expired; create a new one before sending
- open the review file before sending
- review file has expired; create a new one before opening
- Access denied: path resolves outside allowed directories. If
AI-assisted analysis of stablyai/orca@1136503c6a (2026-08-12).
Data as JSON: /api/errors/e0d6a782abb12a28.
Report an issue: GitHub.