Skip to content

Fix shallow clone deepening hanging in CI#36

Merged
axelniklasson merged 2 commits intomainfrom
axel/lin-62864-automatic-deepening-of-shallow-repo-doesnt-seem-to-work
Apr 2, 2026
Merged

Fix shallow clone deepening hanging in CI#36
axelniklasson merged 2 commits intomainfrom
axel/lin-62864-automatic-deepening-of-shallow-repo-doesnt-seem-to-work

Conversation

@axelniklasson
Copy link
Copy Markdown
Collaborator

@axelniklasson axelniklasson commented Apr 1, 2026

Something ended up hanging the deepening for linear-app (example run) so this is Claude and I's attempt to at least get that error visible so we can come up with a fix. I validated locally that automatic deepening works from a shallow repo, so it is likely something CI-related resulting in the deepening hanging.

Changes:

  • stdio: ["ignore", "ignore", "pipe"] — closes stdin so git can't hang waiting for input
  • timeout: 30_000 — 30s hard timeout enforced at the OS level (SIGTERM), independent of the event loop

🤖 Generated with Claude Code

Towards LIN-62864

execSync with stdio: "pipe" created a pipe for stdin, causing git to
hang if a credential helper tried to prompt for input. Additionally,
execSync blocks the event loop, so the global setTimeout timeout could
never fire — leaving no safety net for hanging fetches.

Fix by setting stdin to "ignore" (so git can't block on input) and
adding a 30s timeout directly on execSync (enforced at OS level via
SIGTERM, independent of the event loop).

Fixes LIN-62864

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
@linear-code
Copy link
Copy Markdown

linear-code bot commented Apr 1, 2026

@axelniklasson axelniklasson requested a review from RomainCscn April 1, 2026 13:12
@axelniklasson axelniklasson merged commit 54cc32f into main Apr 2, 2026
2 checks passed
@axelniklasson axelniklasson deleted the axel/lin-62864-automatic-deepening-of-shallow-repo-doesnt-seem-to-work branch April 2, 2026 05:00
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