fix(audit): resolve lint global, compaction metrics, and nudge id

This commit is contained in:
William Valentin
2026-02-15 21:54:12 -08:00
parent 50dcff5ea6
commit 948d589ac3
7 changed files with 106 additions and 11 deletions
@@ -9,6 +9,9 @@ Scope: Production-risk-first audit of bugs, code improvements, and feature oppor
- ✅ F-006 addressed: inbound HTTP request bodies now enforce a configurable max-size limit (`server.max_request_body_bytes`) with `413 Payload Too Large` responses.
- ✅ F-007 addressed: `ToolExecutor` timeout timer handles are now cleared in `finally`, preventing orphan timers on fast/failed tool calls.
- ✅ F-016 partially addressed: gateway + webhook body readers were consolidated into shared utility `src/utils/httpBody.ts` with size-limit enforcement.
- ✅ F-005 addressed: ESLint JS globals now include `FileReader`, removing UI false-positive lint failures for attachment handling code.
- ✅ F-010 addressed: `session.compact` audit events now emit actual message counts for `messages_before/messages_after` (tokens remain in token fields).
- ✅ F-012 addressed: synthetic repeated-tool nudge no longer emits invalid `tool_result.tool_use_id`; nudge is injected as plain user text guidance.
## Executive Summary
+15
View File
@@ -2463,6 +2463,21 @@
"docs/deployment/PRODUCTION.md"
],
"test_status": "targeted: pnpm test:run src/gateway/server.test.ts src/automation/webhooks.test.ts src/tools/executor.test.ts src/config/schema.test.ts src/gateway/ui/lib/markdown.test.ts src/utils/httpBody.test.ts + pnpm typecheck"
},
"audit-followup-lint-compaction-nudge": {
"status": "completed",
"date": "2026-02-16",
"updated": "2026-02-16",
"summary": "Second audit remediation batch: fixed ESLint browser globals mismatch for FileReader, corrected compaction audit event message-count fields, and replaced invalid synthetic tool_result nudge IDs with plain-text nudge guidance in NativeAgent tool loop.",
"files_modified": [
"eslint.config.js",
"src/backends/native/orchestrator.ts",
"src/backends/native/orchestrator.test.ts",
"src/backends/native/agent.ts",
"src/backends/native/agent.test.ts",
"docs/plans/analysis/2026-02-16-codebase-audit-report.md"
],
"test_status": "pnpm test:run src/backends/native/agent.test.ts src/backends/native/orchestrator.test.ts + pnpm typecheck passing"
}
},
"overall_progress": {