Client Error Reporting
Overview
Automatic reporting of task failures to the central API (neo-backend), making errors visible to the team instead of staying silently in local NeDB.
How it works
When a task reaches Failure status with an error, the pipeline's tap callback fires reportClientError. A module-level Set<string> prevents duplicate reports across the 5 updateTaskPipe calls. The set is cleared on task retry.
Features
- Automatic error reporting on any task failure
- Payload includes app version, task type, serialized error chain, OS/arch context
- Fire-and-forget: never blocks the task flow or crashes the app
- Deduplication per task to avoid flooding the API
Key files
src/protocol/bcyipApi.ts—reportClientError()function andClientErrorPayloadinterfacesrc/services/fileProtect/taskActions.pipe.ts— Tap callback with deduplication logic
Technical decisions
- Fire-and-forget rather than awaiting: reporting must never delay user operations or crash the app if the backend is unreachable.
- Module-level Set for deduplication: simple and effective given the single-threaded renderer context.
- Existing
wrap()with Bearer auth: reuses the project's standard API call pattern, no new HTTP client needed.
Known issues
- No retry on failed reports (acceptable for fire-and-forget telemetry)
Next steps
- Dashboard in neo-backend to visualize reported errors