You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The CodeQL SHA-256 detour was a knee-jerk response to a false
positive. MD5 was the correct pragmatic choice — it's not a password
hash, it's namespacing local cache files. Dismissed the CodeQL
alerts (47, 48) as 'won't fix' with the context.
Keeping the try/catch restoration on `issues.ts` invalidation
helpers from ec0279c (the cursor-bot finding was legitimate).
* **Three Sentry APIs for span custom attributes with different capabilities**: Three Sentry span APIs with different attribute capabilities: (1) \`/trace/{traceId}/\` — hierarchical tree; \`additional\_attributes\` enumerates requested attrs; returns \`measurements\` (zero-filled on non-browser, stripped by \`filterSpanMeasurements()\`). (2) \`/projects/{org}/{project}/trace-items/{itemId}/\` — single span full detail; ALL attributes as \`{name,type,value}\[]\` automatically. (3) \`/events/?dataset=spans\&field=X\` — list/search; explicit \`field\` params. \`--fields\` flag filters JSON output AND requests extra API fields via \`extractExtraApiFields()\`. \`FIELD\_GROUP\_ALIASES\` supports shorthand expansion.
* **Update notification rate-limited via last\_notified metadata + TTY gate**: \`src/lib/version-check.ts\`\`getUpdateNotification()\` now enforces a 24h rate limit via \`KEY\_LAST\_NOTIFIED\` metadata + an in-process latch (\`notifiedThisRun\`) plus a \`process.stderr.isTTY\` gate. Non-TTY invocations never see the banner (scripts, CI, \`| cat\`). \`setLastNotifiedNow()\` persists on emit; the latch prevents double-emit within a single process. Tests must mock \`process.stderr.isTTY = true\` AND reset the in-process latch between cases via the exported \`\_resetNotificationStateForTests()\` helper. Mirrors the pattern of other one-shot hints in the CLI.
* **I/O concurrency limits belong at the call site, not in generic combinators**: I/O concurrency limits belong at the call site, not in generic combinators. Pattern: module-scoped \`pLimit()\` with named constant (e.g., \`STAT\_CONCURRENCY = 32\` in \`project-root.ts\`, \`CACHE\_IO\_CONCURRENCY\` in \`response-cache.ts\`, \`pLimit(50)\` in \`code-scanner.ts\`). Keeps combinators pure, makes budget explicit at I/O boundary. stat() lighter than full reads — ~32 for stats vs ~50 for reads, well below macOS's 256 FD ceiling.
* **Isolated adapter coverage via fetch mocking in test/lib/**: To get CodeCov coverage on API-calling functions (e.g., hex-id-recovery adapters, api-client functions), write tests in \`test/lib/\*.coverage.test.ts\` or \`test/lib/\*.adapters.test.ts\` that mock \`globalThis.fetch\` via \`mockFetch()\` from \`test/helpers.js\`, call \`setAuthToken()\` + \`setOrgRegion()\` in \`beforeEach\`, and invoke the REAL function. Tests in \`test/e2e/\` or tests that stub the exports via \`spyOn\`/\`mock.module\` give ZERO coverage to the mocked function body. Use \`useTestConfigDir()\` for DB isolation. Pattern example: \`test/lib/api-client.coverage.test.ts\` and \`test/lib/hex-id-recovery.adapters.test.ts\`. Mock responses must include ALL Zod-required fields — minimal stubs fail schema validation with a noisy \`ApiError\`.
0 commit comments