Skip to content

fix(cli): re-land stalled-stream watchdog with post-v1.17.4 test wiring - #12438

Merged
iscekic merged 1 commit into
mainfrom
fix/rewire-watchdog-tests
Jul 21, 2026
Merged

fix(cli): re-land stalled-stream watchdog with post-v1.17.4 test wiring#12438
iscekic merged 1 commit into
mainfrom
fix/rewire-watchdog-tests

Conversation

@iscekic

@iscekic iscekic commented Jul 21, 2026

Copy link
Copy Markdown
Collaborator

Re-lands #12249 (reverted by open PR #12435) and fixes the compile error that broke @kilocode/cli typecheck on main.

What broke

#12249's test (packages/opencode/test/kilocode/session-stream-watchdog.test.ts) imported three modules that 2855ebbe48 refactor: kilo compat for v1.17.4 had already removed/relocated on main:

  • Reference / RepositoryCache from ../../src/reference/* — consolidated into packages/core
  • Ripgrep from @opencode-ai/core/filesystem/ripgrep — moved to @opencode-ai/core/ripgrep

The PR's CI ran five days before merge against a branch tip that still carried the old files, so the squash merge landed the importing test onto a main that no longer had the modules → TS2307 plus cascading TS2345/TS2322.

Fix

Fix-forward instead of reverting the production fix in packages/opencode/src/session/llm.ts:

  • Point RepositoryCache at @opencode-ai/core/repository-cache and Ripgrep at @opencode-ai/core/ripgrep.
  • Drop the now-nonexistent Reference.defaultLayer from the test's layer stack (three sites), matching the current full-stack sibling session-prompt-compaction-safety.test.ts, which builds the same Session/SessionProcessor/ToolRegistry graph without it.

Net diff is 2 insertions / 6 deletions in one test file.

Verification

  • bun run typecheck (from packages/opencode/) — passes.
  • bun test ./test/kilocode/session-stream-watchdog.test.ts — 3 pass, 0 fail.

Supersedes #12435 (revert can be closed).

PR #12249 was reverted (open PR #12435) because its test imported three
modules that v1.17.4 compat (2855ebb) removed/moved:

- Reference/RepositoryCache from ../../src/reference/* (now packages/core)
- Ripgrep from @opencode-ai/core/filesystem/ripgrep

Re-land the production fix by pointing RepositoryCache and Ripgrep at
@opencode-ai/core/{repository-cache,ripgrep} and dropping the now-gone
Reference.defaultLayer from the layer stack, matching the current
full-stack sibling (session-prompt-compaction-safety.test.ts).

Typecheck passes; all 3 watchdog tests pass.
@iscekic iscekic self-assigned this Jul 21, 2026
@kilo-code-bot

kilo-code-bot Bot commented Jul 21, 2026

Copy link
Copy Markdown
Contributor

Code Review Summary

Status: No Issues Found | Recommendation: Merge

Verified against current main: RepositoryCache and Ripgrep are correctly re-pointed to @opencode-ai/core/repository-cache and @opencode-ai/core/ripgrep (both export defaultLayer), and the removed Reference.defaultLayer references have no remaining usages in the file. The change matches the layer wiring already used in the sibling session-prompt-compaction-safety.test.ts. Test-only change, no user-facing behavior, so no changeset is needed.

Files Reviewed (1 files)
  • packages/opencode/test/kilocode/session-stream-watchdog.test.ts

Reviewed by claude-sonnet-5 · Input: 22 · Output: 3.1K · Cached: 443.8K

Review guidance: REVIEW.md from base branch main

@iscekic
iscekic enabled auto-merge (squash) July 21, 2026 19:05
@iscekic
iscekic merged commit 016fa42 into main Jul 21, 2026
28 checks passed
@iscekic
iscekic deleted the fix/rewire-watchdog-tests branch July 21, 2026 19:52
t7tran pushed a commit to t7tran/kilocode that referenced this pull request Aug 14, 2026
…Kilo-Org#12438)

PR Kilo-Org#12249 was reverted (open PR Kilo-Org#12435) because its test imported three
modules that v1.17.4 compat (7a1394e) removed/moved:

- Reference/RepositoryCache from ../../src/reference/* (now packages/core)
- Ripgrep from @opencode-ai/core/filesystem/ripgrep

Re-land the production fix by pointing RepositoryCache and Ripgrep at
@opencode-ai/core/{repository-cache,ripgrep} and dropping the now-gone
Reference.defaultLayer from the layer stack, matching the current
full-stack sibling (session-prompt-compaction-safety.test.ts).

Typecheck passes; all 3 watchdog tests pass.
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.

2 participants