Repository navigation
refactor: halve code comments and cap comment blocks at four lines - #21514
Merged
Merged
Conversation
…ive, packaging and root files
only21mil
added a commit
to only21mil/t3code
that referenced
this pull request
Nov 1, 2026
Main renamed the provider adapter registry layer (pingdotgg#26238), changed layerWsRpc to take four arguments and need ScratchThreadPromotion (pingdotgg#26767), and caps comment blocks at four lines (pingdotgg#21514). The importer layer, the ACP session RPC test and the importNativeHistory docblock follow suit. The pending-history browser test now asserts through expect.element, as AGENTS.md asks of browser tests. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This was referenced Nov 1, 2026
This was referenced Nov 7, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Comment lines kept growing after https://git.cafe/pingdotgg/t3code/pulls/19559, mostly as long "why" blocks that restate context the code already shows. This PR cuts JS/TS comment lines from 26,014 to 12,863 and adds checks so they don't grow back.
Prevention
t3code/no-low-value-commentsfails a comment block over 4 lines (license headers exempt). Before this PR, about half of all comment lines sat in blocks of 4+ lines.#1234issue or PR number (TODOs,regression: #123test markers,owner/repo#123, code spans, and hex colors are exempt) and the copied@public Service construction is part of the canonical Effect module API.line.Cleanup
Comments that restate names, narrate steps, label sections, or record history are deleted. Remaining why-comments are cut to the constraint they carry. Code is untouched: every changed file parses to the same Oxc AST as
mainonce comments are ignored, and every directive comment is kept (1,835 files checked). Twooxlint-disablelines lost the comment above them that gave the reason, so the reason is now inline. The non-JS files that changed are marketing.astro, Rust, shell, PowerShell, and one Python script, all comment-only.vp lint(0 errors) and the lint plugin tests (289 passed) pass on a Blacksmith testbox.Written by
claude-opus-5-5(Claude Code, in T3 Code), withgpt-6.1-solchildren doing the per-slice edits.🤖 Generated with Claude Code