TraceMachina / TraceMachina/nativelink

Restarting worker with directory cache gives "Destination directory already exists" / "Failed to hardlink newly cached directory"

Open
#2,095 2 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
Rust
Stars
1.6k
Forks
244
Avg merge
1d 16h
Merged PRs (30d)
54

Description

I see:

^[^[  2025-12-12T19:58:54.780199Z  WARN nativelink_worker::running_actions_manager: Directory cache failed, falling back to traditional download, digest: DigestInfo("2c6786e19c74725b23307422bc0d9bfab5ea04b130e56d31e726df03776ea082-166"), e: Error { code: InvalidArgument, messages: ["Destination directory already exists: /Users/user/Work/nativelink/work/df72a46e-f96f-4641-b17c-d8f8fa2bb0b5/work", "Failed to hardlink newly cached directory"] }

Most likely this is due to workers crashing with state still on disk.

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start by reproducing a worker restart while the directory cache state remains on disk, then trace the directory-cache handling that reports “Destination directory already exists” and “Failed to hardlink newly cached directory.” Done means restarting a worker no longer produces these errors for existing on-disk state and the directory cache behavior remains correct.

Written by the indexing model from the issue text.

Assessment

Tech stack
rust
Domain
backend, build-system
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.