Conversation
…convention
telemetry_public was the sole tool returning a bare {action, result} envelope.
Every other oddkit tool (including telemetry_policy per PR #108) returns the
full {action, result, server_time, assistant_text, debug} shape.
Canon reference: klappy://docs/appendices/epoch-8-2 — server_time in every response.
Precedent: PR #108 — telemetry_policy envelope conformance.
Changes:
- workers/src/index.ts: telemetry_public handler emits full envelope on both success and not-configured error paths
- workers/test/canon-tool-envelope.smoke.mjs: add telemetry_public assertion via expectFullEnvelope
Caught by v0.21.0 regression test sweep (2026-04-20).
Deploying with
|
| Status | Name | Latest Commit | Preview URL | Updated (UTC) |
|---|---|---|---|---|
| ✅ Deployment successful! View logs |
oddkit | a024e88 | Commit Preview URL Branch Preview URL |
Apr 20 2026, 12:10 PM |
🔍 Independent Sonnet 4.6 validator — release-validation-gatePer Agent: I have everything I need. Here is the complete validation report. VALIDATION REPORT — PR #124Verdict: PASS_WITH_NOTESCheck-by-check
Findings1. [LOW] Smoke test cannot exercise the not-configured error path The claim states "both success and not-configured error paths" have the full envelope. The code assertion for both paths is correct. However, the smoke test ( This is not a blocking defect — the not-configured path is simple and verified by code inspection. But the PR claim slightly overstates smoke-test coverage. Flag for documentation honesty, not for merge-blocking. 2. [LOW / PRE-EXISTING] Error location inconsistency between the two error paths Not-configured path surfaces error at { "result": { "error": "Telemetry queries not configured…" } }Query-failure path (inner catch) surfaces error at { "result": { "data": { "error": "Query execution failed." }, "generated_at": "…" } }A consumer parsing errors must check two different locations depending on failure type. This inconsistency is pre-existing — not introduced by this PR (the not-configured Recommendationmerge-to-main-safe All 14 checks pass. Both findings are low-severity: finding #1 is a truthfulness note about coverage claims (not a code defect), and finding #2 is a pre-existing design inconsistency outside this PR's scope. The envelope implementation is correct on both return paths, typecheck is clean, scope is tight, and no forbidden files were touched. Dispatched per release-validation-gate canon. Same-session smoke + self-calls do not satisfy; this is the independent verification. |
Bumps version in package.json, workers/package.json, and both lockfiles. Fills CHANGELOG [Unreleased] with 0.22.0 entries covering PR #124 (telemetry_public envelope conformance) and PR #125 (catalog debug.generated_at response time + new index_built_at field). MINOR bump: both fixes add envelope fields consumers can rely on. Both bugs caught during the v0.21.1 regression test sweep. Pre-commit hook verified version sync and typecheck pass. No code or test changes in this PR — documentation + version only.
Main shipped 0.22.0 via PR #128 while this branch was in Sonnet 4.6 validator dispatch. PR #128 backfilled CHANGELOG + version bump covering the envelope-conformance fixes from PR #124 (telemetry_public) and PR #125 (catalog generated_at). Per klappy://canon/constraints/release-validation-gate Rule 3 (canon outranks session artifacts), this refactor is re-versioned to 0.23.0. The handoff's "ship as 0.22.0" recommendation was session-scoped; main- reality is the canon. Resolution: - CHANGELOG.md: my encode D5+D9 content moves to a new [0.23.0] section above the existing [0.22.0] (telemetry + catalog); added a version- note blockquote explaining the bump. - package.json / workers/package.json / both lockfiles: 0.22.0 → 0.23.0. - workers/src/orchestrate.ts: auto-merged cleanly (catalog fix touched runCatalog, encode refactor touched discoverEncodingTypes + classifier call sites; zero overlap). - workers/test/canon-tool-envelope.smoke.mjs: auto-merged cleanly (additive on both sides). Verified: - tsc --noEmit clean - governance-parser.test.mjs 105/105 pass - CHANGELOG structure: [Unreleased] [0.23.0] [0.22.0] [0.21.1] [0.21.0]... - All conflict markers removed Sonnet 4.6 validator verdict (session sesn_011CaF5vqjgzN7Mw8s84qvK9, PASS on all 5 corroborations) remains valid for the encode refactor content — the rebase does not touch any matcher code or action behavior. A fresh-context validator re-dispatch will run before promotion per release-validation-gate Rule 2 out of canon-discipline caution.
…23.0) (#126) Migrates oddkit_encode's trigger-word classifier from regex alternation to stemmed phrase-subset matching — the last regex matcher in the canon-parity sweep. Closes the sweep. Originally scoped as 0.22.0 per the P1.3.4 handoff. While this branch was in Sonnet 4.6 validator dispatch, PR #124 (telemetry envelope) and PR #125 (catalog envelope) landed on main and were released as 0.22.0 via PR #128. Per klappy://canon/constraints/release-validation-gate Rule 3 (canon outranks session artifacts), this refactor rebases forward and ships as 0.23.0. Bugbot disposition (Rule 1): - 259170a (first cut, flat stemmedTokens): completed/neutral, high-severity finding on multi-word vocab flattening → fix-forwarded via 113ba11 - 113ba11 (Cursor autofix stemmedPhrases): completed/neutral, low-severity dead-code finding on intersectsStems → fix-forwarded via e404fe0 - e404fe0: completed/success - eaa1234 (CHANGELOG + assertion 16): completed/success - d2acf91 (merge origin/main): Bugbot cancelled (new commit pushed before completion) - 8a0636b (stale-comment fix): completed/success — final head Sonnet 4.6 validator (Rule 2): agent_011CaF5vo8B5UpqtfZAmSeui, session sesn_011CaF5vqjgzN7Mw8s84qvK9 — verdict PASS on all 5 corroborations against eaa1234. Rebase and comment-fix commits on top are textual/version-only and do not touch matcher code. A fresh validator dispatch will run against the main→prod promotion PR per Rule 2. Refs: - Handoff: klappy://odd/handoffs/2026-04-20-p1-3-4-encode-canon-parity - Canon basis: klappy://canon/principles/cache-fetches-and-parses, klappy://canon/principles/vodka-architecture - Binding gate: klappy://canon/constraints/release-validation-gate Non-blocking carry-forward: P13 — Input-E fallback classification (inputs with no canon vocab intersection fall through to types[0] alphabetical = Constraint). Pre-existing behavior, flagged by validator, outside P1.3.4 scope.
The gap
telemetry_publicwas the sole oddkit tool returning a bare{action, result}envelope. Every other tool — includingtelemetry_policyafter PR #108 — returns the full{action, result, server_time, assistant_text, debug}shape.Caught during the v0.21.0 regression test sweep on 2026-04-20.
Canon reference
klappy://docs/appendices/epoch-8-2— "server_time in every response"telemetry_policyThis PR makes reality conform to canon; no new principle is introduced.
What changed
workers/src/index.ts:telemetry_publichandler now emits the full envelope on both the success path and the not-configured error path.startTimecaptured at the top of the handler;debug.duration_msderived from it.result.generated_atpreserved unchanged (in-result timestamp orthogonal to envelopeserver_time).workers/test/canon-tool-envelope.smoke.mjs: added atelemetry_publicassertion via the existingexpectFullEnvelopehelper.Verification
npm run typecheckcleanRelease-validation-gate
Do not merge until:
completed(not justin_progress)This is an envelope-behavior change; the validator applies.
Note
Medium Risk
Medium risk because it changes the
telemetry_publictool’s response contract (addsserver_time,assistant_text, anddebug), which may affect any consumers that assumed the prior minimal envelope shape.Overview
telemetry_publicnow returns the standard full tool envelope on both success and “not configured” error paths, includingserver_time, a derivedassistant_text(with row-count/error hints), anddebug.duration_mscomputed from a per-requeststartTime.The live smoke test (
canon-tool-envelope.smoke.mjs) is extended to calltelemetry_publicand assert full-envelope conformance via the existingexpectFullEnvelopehelper.Reviewed by Cursor Bugbot for commit a024e88. Bugbot is set up for automated code reviews on this repo. Configure here.