(error?: string)
| 135 | // ── Error Categorization ───────────────────────────────────────────── |
| 136 | |
| 137 | export function categorizeError(error?: string): string | undefined { |
| 138 | if (!error) return undefined |
| 139 | const lower = error.toLowerCase() |
| 140 | if (lower.includes('timeout') || lower.includes('abort')) return 'timeout' |
| 141 | if (lower.includes('rate') || lower.includes('429')) return 'rate_limit' |
| 142 | if (lower.includes('auth') || lower.includes('401') || lower.includes('403')) return 'auth' |
| 143 | if (lower.includes('empty')) return 'empty' |
| 144 | if (lower.includes('race ended')) return 'early_exit' |
| 145 | if (lower.includes('api error') || lower.includes('http')) return 'model_error' |
| 146 | return 'unknown' |
| 147 | } |
| 148 | |
| 149 | // ── Query: Raw Events ──────────────────────────────────────────────── |
| 150 |
no outgoing calls
no test coverage detected