Memex Admin
Dashboard
API Keys
Policies
Frontend + Desktop: No Silent Catch
Repository: mem-labs/mem
Back to Policies
Cancel
active
Updated Feb 19, 2026, 9:36 PM
Name
Status
active
inactive
Markdown
Frontend and desktop runtime code must not silently swallow exceptions. Rationale: - Silent catches hide failures, break observability, and make recovery behavior unpredictable. Scope: - PR review policy for runtime code under: - `domains/frontend/mem-client/src/**` - `domains/typescript/mem-client-desktop/src/**` - `domains/typescript/mem-client-desktop/preload/**` - Excludes tests and stories. Trigger: - A PR adds or changes `catch` blocks in scope. Approval checks: 1) New/changed catch blocks are not empty and do not use pass-only suppression. 2) Each new/changed catch block performs at least one explicit handling action: - rethrow, - structured logger call, - explicit fallback return/path. 3) Catch blocks that intentionally continue execution include an explicit fallback/control-flow path (not silent swallow-and-continue). Evidence: - Diff shows handling actions in each changed catch path. Exception path: - Allow deviation only when all are true: 1) PR description includes `Policy Exception: frontend-desktop-no-silent-catch`. 2) PR explains why suppressing the error is safe for this path. 3) PR documents compensating signal (for example metrics/logging/guard rails) and fallback behavior. Decision: - Return NOT APPROVED when trigger is met and exceptions are silently suppressed without a valid exception.
Cancel
Save Policy