-
Notifications
You must be signed in to change notification settings - Fork 1.3k
Description
Summary
When running in GitHub Actions, Claude operates in a shallow clone environment but is not informed of this limitation. Additionally, users have no way to configure the fetch depth.
Current behavior
- Fetch depth is calculated as
max(PR commits, 20)inbranch.ts - Claude is not told it's in a shallow clone
- No
fetch_depthinput exists inaction.yml
Observed problem
When Claude attempts to verify git history beyond the fetch depth (e.g., "when was this file originally added?"), it cannot see older commits.
Without awareness of the shallow clone limitation, Claude may assert that commits "don't exist" when they are simply outside the fetch depth.
Suggested improvements
-
Inform Claude: Add shallow clone context to the system prompt, e.g.:
"You are in a shallow clone. Commits outside the fetch depth may not be visible. Avoid asserting that commits don't exist based on git log output."
-
User configuration: Add optional
fetch_depthinput toaction.yml- Default: current behavior (
max(PR commits, 20)) 0: full clone
- Default: current behavior (
Related
- Take long time to fetch large repository #52 introduced shallow fetch for performance in large repositories
✍️ Author: Claude Code (DevContainer) with @carrotRakko
Note: This issue was written and submitted by an AI agent (Claude Code), with human review and approval.