cargo/wrapper, store/archive: a test that compiles inside a run job is refused where its build directory lacks the build script's output file; the archive keeps the output directory alone #104

Open
opened 2026-11-18 13:35:48 +00:00 by xemmerling · 0 comments
Owner

A test job of a person's run was told error, cause cache_unreachable, twice in a row, for a file the job was never given. Production d748ed8d, 2026-11-18 13:28Z. Main has not changed the code involved (wrapper/run.rs, store/archive.rs, drivers/cargo/exec/build.rs are as on d748ed8d).

What ended

Run r80eecae1e1 (party xemmerling, session claude:95a5a02a, head 92b694f961), asked test-x86_64/tilo-app-cli alone.

job what from to outcome
j611-34804 the driver: built the test binary, 8 compiles of its own (found=false) 13:27:52Z 13:28:30Z pass
j611-35284 the run of the binary 13:28:30Z 13:28:37Z error, cache_unreachable
j611-35287 its retry 13:28:37Z 13:28:43Z error, cache_unreachable

Both errors say: refused: reading the build script's output /target/debug/build/tilo-app-cli-d4f18dd45bf6314a/output: No such file or directory (os error 2).

The run's log ends as the one test of the shard starts: Starting 1 test across 1 binary (84 tests skipped), three set-up scripts pass, then tilo-app-cli::tilo_app_cli$surface::zz_print_surface::chats_drafts_block started. Nothing after it.

Where it is made

wrapper/run.rs made_by (line 958): for a compile of cargo's (it has -C metadata) whose --out-dir lies in the profile directory of its OUT_DIR, it reads <OUT_DIR>/../output for the features the build script added, and "one missing is an error". wrapper/entry.rs:96 turns the error into a refusal, and the job ends as t's error.

So a compile ran inside the run job, with the package's OUT_DIR in its environment, as a test of a package with a build script has it, and compiling into /target/debug/deps. The test starts it; the wrapper stands around every compile of the job.

Why the file was not there

A run job builds nothing: its build directory is what the node chose plus the archive's view.

  • The node gave j611-35284 build b-d872186526cc of state dfe66edb9364, "holds 1305 of 1314 needed" (the worker's prepare line at 13:28:30Z). That layer, made at 13:27:25Z, holds no build-script directory of tilo-app-cli at all (262 others), and neither does b-1e02cf49cd53, the other build chosen in those seconds.
  • The archive keeps a build script's output directory only: store::archive::out_dirs takes out_dir from cargo's build-script-executed messages, so debug/build/<package>-<hash>/out comes with the binaries and the file output beside it does not.
  • Fourteen build layers on the node hold debug/build/tilo-app-cli-d4f18dd45bf6314a, all fourteen with output. A run job that is given one of them passes; today this check passed 79 times for CI and 27 times for people.

So whether this test passes depends on which kept build the run job happens to be given, and when it is given one without the directory, the failure is told as t's own and the check is not asked again.

What would close it

The doc of made_by says cargo keeps the script's output beside OUT_DIR, written before it starts the package's compiles. That holds in a build job. In a run job it holds only by the choice of build. Two ways I see:

  1. The archive keeps output beside each out it keeps (out_dirs and keep), so a run job's build directory holds what cargo's would, whatever build lies under it.
  2. made_by takes a missing output in a job that builds nothing as "added none". That names the unit without the features its script added, which the doc calls wrong, so I would not.

I can commission the first with a test (a run from an archive alone, in an empty build directory, whose test compiles with its package's OUT_DIR), if you do not want it yourself. It touches store/archive.rs and its manifest, which are yours, so I ask first.

Beside it

Compile-cache refusals since 11-17 00:00Z, all of them: j603-10955 (11-17 16:45Z, people), j605-532 (01:25Z, spare tier), j607-4610 (05:07Z, spare tier, issue 63), j611-12283 and j611-12284 (10:13Z, test/snippets, people), and these two. Four of the seven are people's runs, and a person sees them as their check erring.

My capture read the node 18 seconds after the first line and found the job's directory gone, as at 10:13Z: a job that ends in seven seconds leaves nothing to read. What I have is saved: the server's and the worker's log around it and the run's log.

14:52Z, a correction to "What would close it"

I wrote the first way as if the archive had forgotten the file. It has not. Reading the archive's tests to write a contract, I found the omission pinned: a_shard_in_an_empty_build_directory_has_its_dependencies_build_script_outputs (store/archive.rs, of 404b1538) writes debug/build/fonts-5555/output into the build directory and asserts that the layer does not hold it, "only what the script made". So keeping output is not a repair of something stated; it reverses a choice of yours, and I should have read that test before proposing it.

What stands is the fact: made_by refuses a compile without output, the archive leaves output out on purpose, and the two meet when a test compiles inside a run job. Which side gives is a design decision and yours: the archive after all, the wrapper for a job that builds nothing, or the wrapper not taking a compile a test starts for a unit of the package whose OUT_DIR it inherited. I withdraw "I can commission the first": I commission none of them without your word, and your silence is not that word.

404b1538's own message describes the same class one file earlier: shards that started on a build directory the build had left hid the missing output directories, and on a fresh node 130 of 180 shards failed. Here the kept build hides the missing output the same way, until a run job is given a build without it.

15:22Z, a second correction: the build I named was the driver's

Under "Why the file was not there" I wrote that the node gave the run job j611-35284 the build b-d872186526cc ("holds 1305 of 1314 needed", "the worker's prepare line at 13:28:30Z") and reasoned from it. That is wrong. Read in order of time, the worker's log has that line at 13:27:53.432Z, directly before the launch of j611-34804, the driver. No build-directory line stands before the launch of j611-35284 (13:28:31.486Z) or of j611-35287 (13:28:38.161Z); the ones at 13:28:36Z to 13:28:37Z belong to two other runs' drivers. In the twenty minutes of log I saved, none of the 172 jobs launched with driver=false has such a line and each of the 34 drivers has two. So I do not know what directory the run job compiled in, and two sentences above fall with it: that the two layers lacking the directory explain the miss, and that "a run job that is given one of them passes".

Established:

  • the two error texts and the jobs they ended;
  • that made_by raises them where <OUT_DIR>/../output cannot be read (wrapper/run.rs:978) and entry.rs:96 refuses;
  • that the archive leaves output out on purpose (archive.rs:1451);
  • that the check passed 79 times for CI and 27 times for people that day and erred in this one run.

Not established:

  • where a run job's build directory comes from here, and why the file was absent in this run and present, or not needed, in the others;
  • whether the compile was started by the test that had just begun, where the run's log ends, or by something else in the job.

I should have put the log's lines in order before attributing one to a job. The job's files were gone before any capture read them, and its log is no longer on the server: t log --run r80eecae1e1 test-x86_64/tilo-app-cli gave 13 lines at 13:32Z and "blob … missing" at 15:17Z. So I cannot close the open points from what is left. For the next refusal my capture fetches the job's row and its run's log within seconds of the server's line.

A test job of a person's run was told `error`, cause `cache_unreachable`, twice in a row, for a file the job was never given. Production d748ed8d, 2026-11-18 13:28Z. Main has not changed the code involved (`wrapper/run.rs`, `store/archive.rs`, `drivers/cargo/exec/build.rs` are as on d748ed8d). ## What ended Run r80eecae1e1 (party xemmerling, session `claude:95a5a02a`, head 92b694f961), asked `test-x86_64/tilo-app-cli` alone. | job | what | from | to | outcome | |---|---|---|---|---| | j611-34804 | the driver: built the test binary, 8 compiles of its own (`found=false`) | 13:27:52Z | 13:28:30Z | pass | | j611-35284 | the run of the binary | 13:28:30Z | 13:28:37Z | error, `cache_unreachable` | | j611-35287 | its retry | 13:28:37Z | 13:28:43Z | error, `cache_unreachable` | Both errors say: `refused: reading the build script's output /target/debug/build/tilo-app-cli-d4f18dd45bf6314a/output: No such file or directory (os error 2)`. The run's log ends as the one test of the shard starts: `Starting 1 test across 1 binary (84 tests skipped)`, three set-up scripts pass, then `tilo-app-cli::tilo_app_cli$surface::zz_print_surface::chats_drafts_block` started. Nothing after it. ## Where it is made `wrapper/run.rs` `made_by` (line 958): for a compile of cargo's (it has `-C metadata`) whose `--out-dir` lies in the profile directory of its `OUT_DIR`, it reads `<OUT_DIR>/../output` for the features the build script added, and "one missing is an error". `wrapper/entry.rs:96` turns the error into a refusal, and the job ends as t's error. So a compile ran inside the run job, with the package's `OUT_DIR` in its environment, as a test of a package with a build script has it, and compiling into `/target/debug/deps`. The test starts it; the wrapper stands around every compile of the job. ## Why the file was not there A run job builds nothing: its build directory is what the node chose plus the archive's view. - The node gave j611-35284 build b-d872186526cc of state dfe66edb9364, "holds 1305 of 1314 needed" (the worker's prepare line at 13:28:30Z). That layer, made at 13:27:25Z, holds no build-script directory of `tilo-app-cli` at all (262 others), and neither does b-1e02cf49cd53, the other build chosen in those seconds. - The archive keeps a build script's output directory only: `store::archive::out_dirs` takes `out_dir` from cargo's `build-script-executed` messages, so `debug/build/<package>-<hash>/out` comes with the binaries and the file `output` beside it does not. - Fourteen build layers on the node hold `debug/build/tilo-app-cli-d4f18dd45bf6314a`, all fourteen with `output`. A run job that is given one of them passes; today this check passed 79 times for CI and 27 times for people. So whether this test passes depends on which kept build the run job happens to be given, and when it is given one without the directory, the failure is told as t's own and the check is not asked again. ## What would close it The doc of `made_by` says cargo keeps the script's output beside `OUT_DIR`, written before it starts the package's compiles. That holds in a build job. In a run job it holds only by the choice of build. Two ways I see: 1. The archive keeps `output` beside each `out` it keeps (`out_dirs` and `keep`), so a run job's build directory holds what cargo's would, whatever build lies under it. 2. `made_by` takes a missing `output` in a job that builds nothing as "added none". That names the unit without the features its script added, which the doc calls wrong, so I would not. I can commission the first with a test (a run from an archive alone, in an empty build directory, whose test compiles with its package's `OUT_DIR`), if you do not want it yourself. It touches `store/archive.rs` and its manifest, which are yours, so I ask first. ## Beside it Compile-cache refusals since 11-17 00:00Z, all of them: j603-10955 (11-17 16:45Z, people), j605-532 (01:25Z, spare tier), j607-4610 (05:07Z, spare tier, issue 63), j611-12283 and j611-12284 (10:13Z, `test/snippets`, people), and these two. Four of the seven are people's runs, and a person sees them as their check erring. My capture read the node 18 seconds after the first line and found the job's directory gone, as at 10:13Z: a job that ends in seven seconds leaves nothing to read. What I have is saved: the server's and the worker's log around it and the run's log. ## 14:52Z, a correction to "What would close it" I wrote the first way as if the archive had forgotten the file. It has not. Reading the archive's tests to write a contract, I found the omission pinned: `a_shard_in_an_empty_build_directory_has_its_dependencies_build_script_outputs` (`store/archive.rs`, of 404b1538) writes `debug/build/fonts-5555/output` into the build directory and asserts that the layer does not hold it, "only what the script made". So keeping `output` is not a repair of something stated; it reverses a choice of yours, and I should have read that test before proposing it. What stands is the fact: `made_by` refuses a compile without `output`, the archive leaves `output` out on purpose, and the two meet when a test compiles inside a run job. Which side gives is a design decision and yours: the archive after all, the wrapper for a job that builds nothing, or the wrapper not taking a compile a test starts for a unit of the package whose `OUT_DIR` it inherited. I withdraw "I can commission the first": I commission none of them without your word, and your silence is not that word. 404b1538's own message describes the same class one file earlier: shards that started on a build directory the build had left hid the missing output directories, and on a fresh node 130 of 180 shards failed. Here the kept build hides the missing `output` the same way, until a run job is given a build without it. ## 15:22Z, a second correction: the build I named was the driver's Under "Why the file was not there" I wrote that the node gave the run job j611-35284 the build b-d872186526cc ("holds 1305 of 1314 needed", "the worker's prepare line at 13:28:30Z") and reasoned from it. That is wrong. Read in order of time, the worker's log has that line at 13:27:53.432Z, directly before the launch of j611-34804, the driver. No build-directory line stands before the launch of j611-35284 (13:28:31.486Z) or of j611-35287 (13:28:38.161Z); the ones at 13:28:36Z to 13:28:37Z belong to two other runs' drivers. In the twenty minutes of log I saved, none of the 172 jobs launched with `driver=false` has such a line and each of the 34 drivers has two. So I do not know what directory the run job compiled in, and two sentences above fall with it: that the two layers lacking the directory explain the miss, and that "a run job that is given one of them passes". Established: - the two error texts and the jobs they ended; - that `made_by` raises them where `<OUT_DIR>/../output` cannot be read (`wrapper/run.rs:978`) and `entry.rs:96` refuses; - that the archive leaves `output` out on purpose (`archive.rs:1451`); - that the check passed 79 times for CI and 27 times for people that day and erred in this one run. Not established: - where a run job's build directory comes from here, and why the file was absent in this run and present, or not needed, in the others; - whether the compile was started by the test that had just begun, where the run's log ends, or by something else in the job. I should have put the log's lines in order before attributing one to a job. The job's files were gone before any capture read them, and its log is no longer on the server: `t log --run r80eecae1e1 test-x86_64/tilo-app-cli` gave 13 lines at 13:32Z and "blob … missing" at 15:17Z. So I cannot close the open points from what is left. For the next refusal my capture fetches the job's row and its run's log within seconds of the server's line.
Sign in to join this conversation.
No labels
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set

Reference
tilo/t#104
No description provided.