Skip to content

fix(cli): disable codegraph in ACP session config test#3663

Merged
esengine merged 1 commit into
main-v2from
fix/acp-test-codegraph-lock
Jun 9, 2026
Merged

fix(cli): disable codegraph in ACP session config test#3663
esengine merged 1 commit into
main-v2from
fix/acp-test-codegraph-lock

Conversation

@esengine

@esengine esengine commented Jun 9, 2026

Copy link
Copy Markdown
Owner

Summary

TestACPFactoryLoadsSessionCwdProjectConfig fails deterministically on any machine that has the codegraph binary installed (and intermittently on others). It builds a full controller through boot.Build with the default config, which starts the codegraph serve --mcp daemon. The daemon opens <workspaceRoot>/.codegraph/codegraph.db, and on Windows that handle outlives ctrl.Close(), so the t.TempDir cleanup of the workspace root fails with unlinkat ... The process cannot access the file because it is being used by another process.

The test only verifies that an ACP session loads project commands from cwd — codegraph is irrelevant to it. Disable codegraph in the test's reasonix.toml, matching the convention the boot tests already use.

Test plan

  • Repro confirmed: go test ./internal/cli -run '^TestACPFactoryLoadsSessionCwdProjectConfig$' -count=5 -> 5/5 FAIL (db lock) before; -count=10 -> 10/10 pass after, ~0.86s (no daemon).
  • go test ./internal/cli green.

TestACPFactoryLoadsSessionCwdProjectConfig builds a full controller via
boot.Build with the default config, which starts the codegraph serve
daemon when the binary is installed. The daemon opens
<workspaceRoot>/.codegraph/codegraph.db and on Windows holds the handle
past Close, so t.TempDir cleanup fails with "being used by another
process". The test only exercises ACP project-command loading, so turn
codegraph off — matching the boot tests' convention.
@esengine esengine requested a review from SivanCola as a code owner June 9, 2026 10:07
@github-actions github-actions Bot added v2 Go rewrite (1.x) — main-v2 branch, active development tui Terminal UI / CLI (internal/cli, internal/control) labels Jun 9, 2026
@esengine esengine merged commit 61c99ad into main-v2 Jun 9, 2026
10 checks passed
@esengine esengine deleted the fix/acp-test-codegraph-lock branch June 9, 2026 10:13
SuMuxi66 pushed a commit to SuMuxi66/DeepSeek-Reasonix that referenced this pull request Jun 10, 2026
TestACPFactoryLoadsSessionCwdProjectConfig builds a full controller via
boot.Build with the default config, which starts the codegraph serve
daemon when the binary is installed. The daemon opens
<workspaceRoot>/.codegraph/codegraph.db and on Windows holds the handle
past Close, so t.TempDir cleanup fails with "being used by another
process". The test only exercises ACP project-command loading, so turn
codegraph off — matching the boot tests' convention.

Co-authored-by: reasonix <reasonix@deepseek.com>
dorokuma pushed a commit to dorokuma/DeepSeek-Reasonix that referenced this pull request Jun 10, 2026
TestACPFactoryLoadsSessionCwdProjectConfig builds a full controller via
boot.Build with the default config, which starts the codegraph serve
daemon when the binary is installed. The daemon opens
<workspaceRoot>/.codegraph/codegraph.db and on Windows holds the handle
past Close, so t.TempDir cleanup fails with "being used by another
process". The test only exercises ACP project-command loading, so turn
codegraph off — matching the boot tests' convention.

Co-authored-by: reasonix <reasonix@deepseek.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

tui Terminal UI / CLI (internal/cli, internal/control) v2 Go rewrite (1.x) — main-v2 branch, active development

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant