Skip to content

(janitor/dead-code): remove unused wl-sdk ops/dolthub barrel files - #5831

Open
kilo-code-bot[bot] wants to merge 1 commit into
mainfrom
janitor/dead-code/wl-sdk-barrels
Open

(janitor/dead-code): remove unused wl-sdk ops/dolthub barrel files#5831
kilo-code-bot[bot] wants to merge 1 commit into
mainfrom
janitor/dead-code/wl-sdk-barrels

Conversation

@kilo-code-bot

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

Copy link
Copy Markdown
Contributor

What was deleted

  • packages/wl-sdk/src/dolthub/index.ts (55 lines)
  • packages/wl-sdk/src/ops/index.ts (64 lines)

Two dead barrel re-export files in the private @kilocode/wl-sdk package.
No other files changed.

Evidence it was unreachable

  • src/index.ts (the package's public surface, resolved via package.json
    exports["."]) re-exports every symbol directly from the individual
    modules (./dolthub/api, ./ops/join, ...) and never imports ./dolthub
    or ./ops — the barrels are bypassed.
  • package.json exports only maps ".", "./client", and "./types";
    the ops/ and dolthub/ directories are not importable subpaths.
  • Repo-wide searches for ops/index, dolthub/index, wl-sdk/ops,
    wl-sdk/dolthub, wl-sdk/src/ops, wl-sdk/src/dolthub, and directory
    imports from './ops' / from './dolthub' return zero matches outside
    the barrels' own lines.
  • The only consumers of @kilocode/wl-sdk (services/wasteland/*) all
    import from the root specifier @kilocode/wl-sdk, which resolves to
    src/index.ts, never to either barrel.
  • git log shows both barrels were added in the same commit (feat(wasteland): admin review inbox, drawer graph navigation, rigs page filters #2706) as the
    root src/index.ts, which took the direct re-export approach from the
    start — the barrels were superseded immediately and never referenced.

Dynamic and configured entry points checked

  • The package is private: true, version 0.0.0 (not published);
    main/types/exports all resolve to src/index.ts (plus
    client.ts/types.ts), not these barrels.
  • No Cloudflare binding, Durable Object, queue, cron, alarm, RPC, workflow,
    or wrangler configuration references either file — wl-sdk is a
    pure-TypeScript SDK with no Worker configuration of its own.
  • No import(), require(), export * from, or side-effect import points
    at either file; both are pure re-export files with no module-level side
    effects, so removal changes no initialization behavior.
  • No .plans/.specs/docs/scripts/CI/dev-tooling reference the barrels;
    the README "Layout" lists the directories' modules, not these index files.
  • A fresh clone of Kilo-Org/kilocode (the external API consumer) contains
    no reference to wl-sdk, WlClient, or dolthub.

Contract and compatibility considerations

  • Both barrels only re-export symbols that are already re-exported by
    src/index.ts, so deletion removes no public surface and orphans no
    other module.
  • ops/index.ts is already stale — it omits edit, state,
    accept-upstream, mutate, and several type aliases that the root
    src/index.ts exports — consistent with it being abandoned in favor of
    the root barrel.
  • No persisted data, migration, or rollback concern: pure re-export files.

Validation performed

  • @kilocode/wl-sdk typecheck (tsgo --noEmit): passes before and after.
  • @kilocode/wl-sdk oxlint: 0 warnings, 0 errors (60 files after removal,
    down from 62 — exactly the two deleted files).
  • @kilocode/wl-sdk vitest: 27 test files / 201 tests pass after removal.
  • cloudflare-wasteland (sole consumer) typecheck: passes after removal.
  • git diff --check clean; diff is a two-file, 119-line pure deletion.

packages/wl-sdk/src/dolthub/index.ts and packages/wl-sdk/src/ops/index.ts
are dead code. They are barrel re-export files that nothing imports; the
package's public surface (src/index.ts) re-exports every symbol directly
from the individual modules instead.

Evidence of unreachability:
- src/index.ts (resolved by package.json "exports"["."]) re-exports each
  symbol from its own module (./dolthub/api, ./ops/join, ...) and never
  imports ./dolthub or ./ops (the barrels).
- package.json "exports" only maps ".", "./client", and "./types", so the
  ops/ and dolthub/ directories are not importable subpaths.
- Repo-wide searches for "ops/index", "dolthub/index", "wl-sdk/ops",
  "wl-sdk/dolthub", "wl-sdk/src/ops", "wl-sdk/src/dolthub", and directory
  imports from "./ops"/"./dolthub" return zero matches outside the barrels
  themselves.
- The only consumers of @kilocode/wl-sdk (services/wasteland/*) all import
  from the root specifier "@kilocode/wl-sdk", which resolves to src/index.ts.

Dynamic/configured entry points checked:
- The package is private (not published) and version 0.0.0; main/types/
  exports all resolve to src/index.ts (plus client.ts/types.ts), not these
  barrels.
- No Cloudflare binding, Durable Object, queue, cron, alarm, RPC, workflow,
  or wrangler config references either file (wl-sdk is a pure-TypeScript SDK
  with no Worker configuration of its own).
- No import(), require(), export * from, or side-effect import points at
  either file; they contain no module-level side effects (pure re-exports).
- No .plans/.specs/docs/scripts/CI/dev-tooling reference the barrels; the
  README "Layout" lists the directories' modules, not these index files.
- Kilo-Org/kilocode (the external API consumer) contains no reference to
  "wl-sdk", "WlClient", or "dolthub".

Contract/compatibility:
- Both barrels only re-export symbols already re-exported by src/index.ts,
  so removal deletes no public surface and orphans no other module.
- ops/index.ts is already stale: it omits edit, state, accept-upstream,
  mutate, and several type aliases present in the root src/index.ts,
  consistent with it being abandoned in favor of the root barrel.
- No persisted data, migration, or rollback concern: pure re-export files.

Validation:
- @kilocode/wl-sdk typecheck (tsgo --noEmit) passes before and after.
- @kilocode/wl-sdk oxlint: 0 warnings, 0 errors (60 files after removal,
  down from 62).
- @kilocode/wl-sdk vitest: 27 test files, 201 tests pass after removal.
- cloudflare-wasteland (the sole consumer) typecheck passes after removal.

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 2, 2026
@kilo-code-bot

kilo-code-bot Bot commented Sep 2, 2026

Copy link
Copy Markdown
Contributor Author

Code Review Summary

Status: No Issues Found | Recommendation: Merge

Files Reviewed (2 files)
  • packages/wl-sdk/src/dolthub/index.ts
  • packages/wl-sdk/src/ops/index.ts

Reviewed by grok-4.6 · Input: 112.7K · Output: 4.4K · Cached: 101.5K

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