Skip to content

(janitor/comments): remove narration and banner comments from app-builder - #6351

Open
kilo-code-bot[bot] wants to merge 1 commit into
mainfrom
janitor/comments-app-builder
Open

kilo-code-bot[bot] wants to merge 1 commit into
mainfrom
janitor/comments-app-builder

Conversation

@kilo-code-bot

@kilo-code-bot kilo-code-bot Bot commented Sep 19, 2026

Copy link
Copy Markdown
Contributor

Comment-only cleanup of services/app-builder (App Builder Cloudflare Worker: git HTTP protocol, preview Durable Object, handlers, schemas, utils, and its git tests). All changes are comment deletions plus directly resulting blank-line removals — no behavior, type, test, or public-API changes.

Package or topic area cleaned

services/app-builder — the git clone/push protocol pipeline (src/git/), the preview and git-repository Durable Objects, HTTP handlers, API schemas, shared utils, and the service's own unit and integration tests.

Files touched (21)

  • src/git/git-receive-pack-service.ts, src/git/git-clone-service.ts, src/git/git-protocol-utils.ts, src/git/fs-adapter.ts, src/git/memfs.ts
  • src/handlers/git-protocol.ts, src/handlers/init.ts, src/handlers/preview.ts, src/handlers/delete.ts, src/handlers/migrate-to-github.ts
  • src/preview-do.ts, src/git-repository-do.ts, src/index.ts, src/types.ts, src/api-schemas.ts
  • src/utils/auth.ts, src/utils/push-notification.ts
  • src/git/git-receive-pack-service.test.ts, src/git/git-clone-service.test.ts
  • src/_integration_tests/test-git-head-and-history.ts, src/_integration_tests/test-git-integration.ts, src/_integration_tests/git-test-helpers.ts

Comment lines removed

  • 375 comment lines removed
  • 25 directly resulting blank lines removed
  • 5 lines had only trailing inline comments deleted (code re-added unchanged); net diff: 5 insertions(+), 405 deletions(-) across 21 files

Categories of noise removed

  • Step-by-step narration of the immediately following line (git protocol, TAR parsing, ref updates)
  • Section banners and // === / // --- separators, including "Step N" and "Test N" banners duplicating adjacent log calls and test-suite names
  • Routing dispatch restatements (// Handle X requests above the matching pattern check)
  • Numbered migration steps (// 1. Fetch a GitHub token via git-token-service)
  • Test narration of setup, execution, and assertions
  • Stale/misleading comments (e.g. "skip PACK header check" contradicting the code, a self-referential // src/types.ts path comment)
  • Trailing inline restatements (// P, // Write length, // Decode base64 to binary)

Important comments intentionally retained

  • Git wire-protocol semantics: symref-first capability convention, empty-repo capabilities^{} advertisement, sideband/unpack-status rules, pkt-line format docs
  • TAR format offsets, octal size field, type flag, end-of-archive marker
  • Safety invariants: persist-before-success on push, oversized pack/object pre-validation, ref-target-exists checks, HEAD bootstrap on first push
  • Compatibility: legacy token fallback (grants full), empty-body init clients, raw-OID HEAD legacy-repo handling
  • External platform behavior: pkill exit codes, DO deleteAll() also clearing SQLite tables, cf-git listBranches() hang workaround, ephemeral GitHub token refresh
  • 7-day deletion grace period rationale; CORS preflight keep-alive rationale; the @ts-expect-error directive (untouched)
  • Empty-catch comments required by the no-empty lint rule (verified: removing them fails oxlint)

Follow-up refactor candidates

None — no deleted comment was load-bearing for understanding beyond what the code expresses.

Validation performed

  • pnpm --filter app-builder typecheck (tsgo): pass
  • oxlint --config .oxlintrc.json services/app-builder/src: 0 errors, 0 warnings
  • pnpm --filter app-builder test (vitest): 4 files, 43/43 passed
  • oxfmt --check services/app-builder/src: clean
  • Diff audit: with all comments stripped, old vs new sources are identical (only comment and blank-line changes); every deleted comment reviewed in the diff

…lder

Comment-only cleanup of services/app-builder. No behavior, types, or
public API changes: 375 comment lines and 25 resulting blank lines
removed across 21 files.

Removed: step-by-step narration of the next line, git-protocol and
TAR-parsing step labels, section banners, routing restatements,
numbered migration steps, test step/phase narration, and a stale
self-referential path comment.

Kept: protocol and TAR format offsets, empty-repo advertisement
semantics, sideband/unpack-status rules, oversized-pack and
persist-before-success invariants, legacy-token compatibility notes,
HEAD bootstrap rule, pkill exit-code semantics, TAR end-of-archive
markers, and no-empty-required empty-catch comments.
@kilo-code-bot kilo-code-bot Bot added the janitor Automated dead-code/duplication cleanup label Sep 19, 2026
@kilo-code-bot
kilo-code-bot Bot enabled auto-merge (squash) September 19, 2026 08:09
@kilo-code-bot

kilo-code-bot Bot commented Sep 19, 2026

Copy link
Copy Markdown
Contributor Author

Code Review Summary

Status: No Issues Found | Recommendation: Merge

Executive Summary

Reviewed 21 files of comment-only cleanup in services/app-builder. Every deleted line is a narration or banner comment (or a directly resulting blank line), and the five inserted lines restore code whose trailing inline comments were dropped, so there are no behavioral, type, or test changes.

Files Reviewed (21 files)
  • services/app-builder/src/_integration_tests/git-test-helpers.ts
  • services/app-builder/src/_integration_tests/test-git-head-and-history.ts
  • services/app-builder/src/_integration_tests/test-git-integration.ts
  • services/app-builder/src/api-schemas.ts
  • services/app-builder/src/git-repository-do.ts
  • services/app-builder/src/git/fs-adapter.ts
  • services/app-builder/src/git/git-clone-service.test.ts
  • services/app-builder/src/git/git-clone-service.ts
  • services/app-builder/src/git/git-receive-pack-service.test.ts
  • services/app-builder/src/git/git-receive-pack-service.ts
  • services/app-builder/src/git/memfs.ts
  • services/app-builder/src/handlers/delete.ts
  • services/app-builder/src/handlers/git-protocol.ts
  • services/app-builder/src/handlers/init.ts
  • services/app-builder/src/handlers/migrate-to-github.ts
  • services/app-builder/src/handlers/preview.ts
  • services/app-builder/src/index.ts
  • services/app-builder/src/preview-do.ts
  • services/app-builder/src/types.ts
  • services/app-builder/src/utils/auth.ts
  • services/app-builder/src/utils/push-notification.ts

Reviewed by deepseek-v4.1-flash · Input: 0 · Output: 0 · Cached: 0

Review guidance: REVIEW.md from base branch main

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

janitor Automated dead-code/duplication cleanup

Projects

None yet

Development

Successfully merging this pull request may close these issues.

0 participants