Skip to content

refactor(discord): remove routine diagnostics and voice content traces - #174279

Merged
steipete merged 3 commits into
mainfrom
deslop/z22-12-discord-diagnostics-20261015
Oct 16, 2026
Merged

steipete merged 3 commits into
mainfrom
deslop/z22-12-discord-diagnostics-20261015

Conversation

@steipete

@steipete steipete commented Oct 16, 2026 •

Copy link
Copy Markdown
Contributor

What Problem This Solves

Discord's routine startup, message, and voice logs contain excessive per-step detail, including spoken wake-name fragments.

User Impact

User impact: Discord logs omit routine trace detail and spoken fragments while retaining actionable failures, lifecycle milestones, and denial guidance; messaging, voice, configuration, and API behavior do not change.

Why This Change Was Made

Remove unread private queue counters, an unused metrics formatter/subscriber, startup/preflight formatting helpers, duplicate request summaries, and log-only voice clocks and arguments. Remove the two wake-name content sinks without changing recognition or playback. Keep actual deployment failure context and a single actionable terminal warning, queue bounds and settlement, access/currentness checks, voice recording, FIFO, cancellation, and resource limits. Producers continue writing raw operational facts; redaction remains owned by designated egress.

This is the Discord area of the channel diagnostics cleanup, deliberately split to keep CI attribution narrow. It removes 483 net production lines across 26 production files (+40/-523); test/support code shrinks 83 lines across 13 files. No public flags, SDK exports, schemas, dependencies, or features are removed.

The subsequent one-line fixture repair makes test/support shrinkage 84 lines across 14 files; the shrink-only baseline repair brings the total to 41 files. Production remains 483 net lines removed.

Related: #104163, #104174, #172944.

Evidence

Targeted formatting passed for all 37 existing changed files, and git diff --check passed. Independent Codex review of the complete combined patch completed P0-P2 scoped-clean with final source verification and no actionable findings. Existing wake-name delivery coverage now also asserts that logs exclude the synthetic spoken fragment and utterance; existing failure, queue, startup, recording, and playback behavior assertions remain.

Reviewed base: 28f5f250e1134ab26ac790d5fad1449ac48e6eb4. Reviewed tracked-patch SHA256: 7b9acf52e93463c27315939936d037b142480b968c6f500948075df1f9d2fd22.

Local runtime tests and targeted types are unqualified in this dependency-free publication worktree; no install or relink was performed. Broad checks belong to exact-head hosted CI. No live channel, device, build, or E2E proof is claimed.

Initial exact-head CI run 38912358698 exercised the changed Discord bundle: 120 files and 1,579 tests passed, while one test still required the removed routine discord inbound log. Its single obsolete positive trace assertion is removed; the same test retains the original text in agent context and excludes it from diagnostic logs. No kept behavior assertion, timeout, retry, or skip changes. The one-line repair independently reviewed P0–P2 scoped-clean with final source verification; targeted repository formatting and diff checks pass. The repaired head's hosted CI remains the broad landing gate; no local runtime/type pass is claimed for this dependency-free publication worktree.

Run 38914426100 passed the repaired runtime case. Its sole primary failure was a shrink-only assertion-safety ratchet: the deleted startup-log file still had an allowlist entry. Remove that obsolete entry; the derived CI gate failure is attributed to this ratchet, not inherited. Production and test behavior are unchanged by the baseline-only repair.

Best-effort tradeoffs accepted

No defensive guard is removed, so there is no newly accepted race, durability, or authorization edge case. The logging privacy invariant from #172944 remains intact, and spoken wake-name content is no longer emitted by these sinks.

@clawsweeper

clawsweeper Bot commented Oct 16, 2026 •

Copy link
Copy Markdown
Contributor

🦞👀
ClawSweeper picked this up.

Pull request received. I will update this pull request when review starts.

ClawSweeper review complete

ClawSweeper finished reviewing this revision. The review result is being finalized.

View the workflow run.

@openclaw-barnacle openclaw-barnacle Bot added channel: discord Channel integration: discord size: L labels Oct 16, 2026
@steipete
steipete marked this pull request as ready for review October 16, 2026 14:00
@chatgpt-codex-connector

chatgpt-codex-connector Bot commented Oct 16, 2026 •

Copy link
Copy Markdown
Contributor

Codex Review Summary

This comment shows the latest Codex review activity on this pull request.

Review Status Commit Review trigger
📝 Code Review ✅ Completed 2026-10-16T14:03:58.436017Z b066f26 Draft marked ready
ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review" or "@codex security review".

Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings.

@clawsweeper clawsweeper Bot added clawsweeper:intake:bug Preliminary submission classification; full source review pending. clawsweeper:intake:needs-repro Preliminary submission classification; full source review pending. labels Oct 16, 2026
@steipete

Copy link
Copy Markdown
Contributor Author

Exact-head landing evidence for 75d4523f9fb4965c30a0c7c0ae8ef8cc112a9f6c.

CI run https://github.com/openclaw/openclaw/actions/runs/38917009106 completed successfully. All 103 check runs for this exact commit were enumerated: 52 success, 50 skipped, 1 neutral, with no failure, cancellation or pending check. Latest commit statuses openclaw/ci-gate, openclaw/security-sensitive-review and openclaw/dependency-review are all successful. An earlier transient security-review failure is superseded by the successful applicable review result; it is not being waived.

The earlier PR-caused failures were repaired, not classified as inherited: the obsolete inbound trace assertion was removed while payload/privacy assertions remain, and the retired startup-log assertion allowance was deleted. No CI reruns, retries, skips or timeout changes were used. Current production delta is 483 net lines removed. Full independent source review and the subsequent assertion-only repair review found no actionable issues; the baseline-only append is mechanical.

The native maintainer workflow failed twice before acquiring an operation lock or submitting a merge: canonical installed tsx 4.23.12 does not match required 4.23.15; the supported tooling owner has fs-safe 0.26.5 rather than required 0.26.6 and cannot refresh this clean feature checkout. No dependencies or guards were changed. Under the campaign's explicit rule 10, using the direct squash-merge endpoint with this exact head precondition bypasses the broken tooling, not CI or review. The PR is mergeable and its head was reverified immediately before submission.

@steipete
steipete merged commit 010e9e6 into main Oct 16, 2026
106 checks passed
@steipete
steipete deleted the deslop/z22-12-discord-diagnostics-20261015 branch October 16, 2026 14:48
steipete added a commit that referenced this pull request Oct 16, 2026
Hourly 38916811035 reported the route inventories as unused, but Vite
loads them through runnerImport and embeds them in the offline shell.
Keep that runtime contract and model the actual named property reads in
Knip through its existing MJS compiler. Preserve Vite discovery and
TypeScript declaration-to-source mapping; add no ignores.

Make four remaining declarations private after #174279 and #174260
removed external logging consumers and #174255 consolidated fixtures.
Their internal callers and behavior remain intact. I18nController was
already removed by #174263.

Proof: all three deadcode export scans have zero findings; the original
baseline had six. The guard passes with pnpm test
test/scripts/check-deadcode-exports.test.ts --maxWorkers=1 (5.67s).
Existing route/build/cache tests and 148 owner/importer cases pass
(199.76s for the owner batch). Owning typechecks, typed lint, boundary
lint, and formatting pass. Negative control and P2 review recorded in
PR evidence.

P2 autoreview is scoped-clean with no actionable findings.
github-actions Bot pushed a commit to Desicool/openclaw that referenced this pull request Oct 17, 2026
openclaw#174279)

* refactor(discord): remove routine diagnostics and voice content traces

* test(discord): retire obsolete inbound trace expectation

* chore(discord): shrink retired startup logger assertion baseline
github-actions Bot pushed a commit to Desicool/openclaw that referenced this pull request Oct 17, 2026
…w#174358)

Hourly 38916811035 reported the route inventories as unused, but Vite
loads them through runnerImport and embeds them in the offline shell.
Keep that runtime contract and model the actual named property reads in
Knip through its existing MJS compiler. Preserve Vite discovery and
TypeScript declaration-to-source mapping; add no ignores.

Make four remaining declarations private after openclaw#174279 and openclaw#174260
removed external logging consumers and openclaw#174255 consolidated fixtures.
Their internal callers and behavior remain intact. I18nController was
already removed by openclaw#174263.

Proof: all three deadcode export scans have zero findings; the original
baseline had six. The guard passes with pnpm test
test/scripts/check-deadcode-exports.test.ts --maxWorkers=1 (5.67s).
Existing route/build/cache tests and 148 owner/importer cases pass
(199.76s for the owner batch). Owning typechecks, typed lint, boundary
lint, and formatting pass. Negative control and P2 review recorded in
PR evidence.

P2 autoreview is scoped-clean with no actionable findings.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

channel: discord Channel integration: discord clawsweeper:intake:bug Preliminary submission classification; full source review pending. clawsweeper:intake:needs-repro Preliminary submission classification; full source review pending. size: L

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant