Skip to content

chore: remove source comments and enforce a zero-comment policy - #157

Merged
cheetahbyte merged 1 commit into
mainfrom
chore/zero-source-comments
Nov 23, 2026
Merged

cheetahbyte merged 1 commit into
mainfrom
chore/zero-source-comments

Conversation

@cheetahbyte

Copy link
Copy Markdown
Contributor

Summary

  • Remove repository-owned source comments and enforce an empty, zero-comment lint baseline across 966 source/config files, including tests, UI components, and inline HTML scripts.
  • Preserve consequential rationale in ADRs and audit records; add the repository-local /delete-comment skill.
  • Replace inline lint/type directives with configuration and move SQL separators into metadata while preserving all 36 historical migration hashes and 205 execution groups.

Why (if needed)

Keep executable source free of redundant, stale, or workaround-justifying commentary without losing architectural decisions or breaking tooling directives.

The cleanup removes 1,973 comment-only lines and yields 831 fewer source/config lines net. Total repository lines increase because the audit and ADRs preserve knowledge outside source.

Evidence

  • bun run check: passed; 1,272 tests passed, 118 opt-in tests skipped, zero failures.
  • bun run lint:comments: zero comments across 966 owned source/config files.
  • bunx --no-install tsc -p tools: passed.
  • Docs checks and site build: passed; the site build emits a CSS sourcemap warning.
  • Controlled checks rejected newly added JS/TS, JSX, inline-script, and non-JS comments while accepting comment-like string data.
  • Independent comparison against 125cefd preserved every historical migration hash and exact SQL execution group; tampered SQL and invalid breakpoint bounds were rejected.
  • All 401 modified existing JS/TS files parse. After ignoring comments and empty JSX comment containers, 397 executable ASTs are unchanged. The four intentional differences are migration wiring, its upgrade fixture, equivalent code-point counting replacing a suppression, and lint configuration.
  • Ten existing YAML/JSON configs retain identical parsed data outside four intentional tooling-config changes. Both Python helpers retain their executable ASTs after removing the redundant docstring.

Risks / rollback

  • This is a broad cleanup. Revert normalized SQL, sidecars, the loader, and generator wrappers together; no new database schema migration is introduced.
  • Non-JS enforcement is lexical, not a replacement for syntax/build checks. React Doctor exceptions now have file-and-rule scope rather than line scope. Intentional empty catches remain allowed without filler comments.
  • Dependencies, ignored generated/build outputs, and Markdown prose are outside owned-source enforcement. Eight executable shell shebangs remain.
  • Live workspace/desktop suites and container image builds were not run. No production data, real credentials, paid inference, or billed workspaces were used.

Follow-ups: #155 and #156. This PR removes the comments and records the debt; it does not implement those fixes.

@github-actions

Copy link
Copy Markdown

React Doctor found no new issues. 🎉

Reviewed by React Doctor for commit 9afa32e.

@cheetahbyte
cheetahbyte merged commit dba4025 into main Nov 23, 2026
11 checks passed
@cheetahbyte
cheetahbyte deleted the chore/zero-source-comments branch November 23, 2026 09:45
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant