anthropics / anthropics/claude-code-action
Bun: Internal error 'directory mismatch for directory' in v1 action on GitHub-hosted runners
- Dominant language
- TypeScript
- Stars
- 8.9k
- Forks
- 2.1k
- Avg merge
- 3d 9h
- Merged PRs (30d)
- 10
Description
## Summary
Every invocation of `anthropics/claude-code-action@v1` from our repo's `review` workflow fails with a Bun internal error during action setup:
```
Internal error: directory mismatch for directory "/home/runner/work/_actions/anthropics/claude-code-action/v1/tsconfig.json", fd 4
```
The error comes from Bun (the runtime the action uses); no user code runs. It reproduces on every PR in our repo.
## Reproduction
A reproducing run from PR #10526 in our repo (trajectory-labs-pbc/agent-c):
https://github.com/trajectory-labs-pbc/agent-c/actions/runs/24585295927/job/71893230564
The failure occurs in the `review` job, during action setup, before any user inputs are consumed.
## Impact
`review` jobs fail on every PR, blocking green CI for repos that require all checks to pass.
## Environment
- Runner: `ubuntu-latest` (GitHub-hosted)
- Action ref: `anthropics/claude-code-action@v1`
- Our repo: public, standard PR-triggered workflow
## Ask
- Pin Bun to a known-good version inside the action, or
- Surface a more actionable error if this is a repo- or path-specific issue, or
- Advise on a workaround we can apply from the caller side.
Happy to provide more logs on request.
Contributor guide
Research direction
Start with the linked PR #10526 workflow run and the `review` job setup failure at `/home/runner/work/_actions/anthropics/claude-code-action/v1/tsconfig.json`. Inspect the Bun runtime used by `anthropics/claude-code-action@v1` and reproduce the directory-mismatch error on `ubuntu-latest`. Done means identifying a reliable action-side fix, actionable error, or caller-side workaround that lets the review job complete.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- bun, typescript
- Domain
- ci-cd
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Quiet
- Clarity
- Mostly clear
- Newbie friendliness
- 42/100