Skip to content

(janitor/comments) remove noise comments across the gastown service - #6791

Merged
kilo-code-bot[bot] merged 1 commit into
mainfrom
kilo/glad-bit-hba
Sep 28, 2026
Merged

kilo-code-bot[bot] merged 1 commit into
mainfrom
kilo/glad-bit-hba

Conversation

@kilo-code-bot

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

Copy link
Copy Markdown
Contributor

Package or topic area cleaned

services/gastown — the container runtime (container/), worker entry point + handlers + tRPC + utils + db tables (src/), and integration/unit tests (test/). The src/dos/ Town DO area was already cleaned by #6153 and was deliberately left untouched here, along with its high-value invariant/race-condition comments.

Files touched

32 files, 6 insertions(+), 503 deletions(-) (~380 comment lines removed, remainder is resulting blank-line whitespace):

  • container/src/: process-manager.ts, control-server.ts, git-manager.ts, types.ts
  • container/plugin/: client.ts, index.ts, types.ts
  • src/: gastown.worker.ts, dos/Town.do.ts (header history + banners only), db/tables/{beads,agent-metadata}.table.ts, handlers/{mayor-tools,mayor,org-towns,rig-agents,town-eviction,towns,wasteland-tools}.handler.ts, trpc/{router,schemas}.ts, util/platform-pr.util.ts
  • test/integration/: convoy-dag, gupp-nudge, http-api, mayor-idle, reconciler, review-failure, rig-alarm, rig-do, town-container, town-deletion tests
  • test/unit/: conversation, convoy-branches tests

Categories of noise removed

  • Section banners (// ── X ───, // ═══, // -- X --) restating route paths, describe titles, function names, or type names
  • Step-by-step test narration of setup, execution, and assertions that duplicate test titles
  • Function/type JSDoc restating the name and signature (Remove a git worktree., Fetch pending nudges..., Sling result (bead + assigned agent), // Agent, // MayorStatus, ...)
  • Commented-out debug logging and event handlers in container/plugin/index.ts
  • Obsolete implementation history (refactor numbers Town-Centric Refactor: Consolidate control plane into TownDO, SDK-based agents, WebSocket streaming #419/Make Cloud Gastown beads-centric: unify all object types into the beads primitive #441 in the TownDO header) and "REMOVE after debugging" markers
  • Apology/"kept for clarity" comments (These are no-ops now but kept for clarity)
  • Restated validation narration (Verify the bead belongs to this rig above an adjacent ownership check)

Important comments intentionally retained

Follow-up refactor candidates

None recorded — no removed comment was load-bearing for understanding the adjacent code.

Validation performed

  • pnpm typecheck (services/gastown): passes
  • gastown lint script (oxlint on src): 0 errors; repo-wide lint-all.sh: identical error set before and after the change (31 pre-existing errors in container/+test/ style rules and a pre-existing apps/extension tsconfig error)
  • pnpm test (unit): 315/315 pass
  • pnpm test:integration: identical pass/fail profile before and after (52 pre-existing environmental failures in both runs)
  • oxfmt --check: clean on the changed files (repo-wide check on the clean tree was already clean)
  • Diff reviewed line-by-line: only comment deletions, blank-line whitespace fallout, and one lint-required comment replacement (// Ignore → // Ignore non-JSON client messages)

Auto-merge on approval.

Comment-only cleanup across services/gastown (container runtime, worker
entry point, handlers, tRPC, utils, db tables, and tests). Deletes
section banners that duplicate describe titles or route paths, step-by-
step test narration of setup/execution/assertions, restated function
and type labels, commented-out code, obsolete history notes (refactor
numbers, "REMOVE after debugging" markers), and apology comments. All
race-condition, invariant, security, auth-topology, spec-reference,
and external-behavior comments are retained, as are all lint/TS
suppressions and the catch-block comments required by the no-empty
lint rule.

Co-authored-by: kiloconnect[bot] <240665456+kiloconnect[bot]@users.noreply.github.com>
@kilo-code-bot kilo-code-bot Bot added the janitor Automated dead-code/duplication cleanup label Sep 28, 2026
@kilo-code-bot
kilo-code-bot Bot enabled auto-merge (squash) September 28, 2026 08:30
'open',
input.convoyTitle,
null, // body
null,

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

SUGGESTION: Unlabeled positional null arguments reduce readability

This INSERT passes four positional null values for body, rig_id, parent_bead_id, and assignee_agent_bead_id. The labels for three of them were removed here while the adjacent rig_id label was kept, so each bare null can now only be mapped back to the column list by position. Consider restoring the body, parent_bead_id, and assignee_agent_bead_id labels (or labeling all four) for consistency.


Reply with @kilocode-bot fix it to have Kilo Code address this issue.

@kilo-code-bot

kilo-code-bot Bot commented Sep 28, 2026 •

Copy link
Copy Markdown
Contributor Author

Code Review Summary

Status: 1 Issue Found | Recommendation: Address before merge

Executive Summary

Comment-only cleanup across services/gastown with no functional, lint, or suppression changes; the single regression is the removal of positional-argument labels from the convoy INSERT in Town.do.ts.

Overview

Severity Count
CRITICAL 0
WARNING 0
SUGGESTION 1
Issue Details (click to expand)

SUGGESTION

File Line Issue
services/gastown/src/dos/Town.do.ts 3665 Labels for body, parent_bead_id, assignee_agent_bead_id positional null args were removed while the adjacent rig_id label was kept, making the call site ambiguous.
Files Reviewed (32 files)
  • services/gastown/container/plugin/client.ts
  • services/gastown/container/plugin/index.ts
  • services/gastown/container/plugin/types.ts
  • services/gastown/container/src/control-server.ts
  • services/gastown/container/src/git-manager.ts
  • services/gastown/container/src/process-manager.ts
  • services/gastown/container/src/types.ts
  • services/gastown/src/db/tables/beads.table.ts
  • services/gastown/src/dos/Town.do.ts - 1 issue
  • services/gastown/src/gastown.worker.ts
  • services/gastown/src/handlers/mayor-tools.handler.ts
  • services/gastown/src/handlers/mayor.handler.ts
  • services/gastown/src/handlers/org-towns.handler.ts
  • services/gastown/src/handlers/rig-agents.handler.ts
  • services/gastown/src/handlers/town-eviction.handler.ts
  • services/gastown/src/handlers/towns.handler.ts
  • services/gastown/src/handlers/wasteland-tools.handler.ts
  • services/gastown/src/trpc/router.ts
  • services/gastown/src/trpc/schemas.ts
  • services/gastown/src/util/platform-pr.util.ts
  • services/gastown/test/integration/convoy-dag.test.ts
  • services/gastown/test/integration/gupp-nudge.test.ts
  • services/gastown/test/integration/http-api.test.ts
  • services/gastown/test/integration/mayor-idle.test.ts
  • services/gastown/test/integration/reconciler.test.ts
  • services/gastown/test/integration/review-failure.test.ts
  • services/gastown/test/integration/rig-alarm.test.ts
  • services/gastown/test/integration/rig-do.test.ts
  • services/gastown/test/integration/town-container.test.ts
  • services/gastown/test/integration/town-deletion.test.ts
  • services/gastown/test/unit/conversation.test.ts
  • services/gastown/test/unit/convoy-branches.test.ts

Fix these issues in Kilo Cloud


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.

1 participant