The compile cache handed four jobs a crate file their dependents were not built against (E0463, E0460), 21:54-21:58Z 11-13 #63

Open
opened 2026-11-13 22:20:47 +00:00 by xemmerling · 1 comment
Owner

Production, 9faf6c61 (the build before your 22:08Z promote). The wrapper, slot and placement files named below are unchanged in 6ebaa239, so this stands for the build production runs now. Nothing was changed on production; no code of mine is in flight.

What happened. No job had ended this way in the 5 h 20 min since the 16:32Z restart. Then four people's jobs ended cache_unreachable within three minutes, 21:54:49 to 21:57:51Z 11-13:

  • j559-80704, cargo build -p tilo-web-desktop for wasm (started 21:49:32): E0463, can't find crate tilo_delivery_protocol (the .rmeta cargo handed it, 627071 bytes as the compile started and now).
  • j559-80090, test/ebook (21:40:48): E0463, runtime_collab (9820695 bytes, both times).
  • j559-80075, test/contacts (21:40:35): E0460, "found possibly newer version of crate tilo_dav which cloud_source_dav depends on".
  • j559-80080, test/notes (21:40:35): E0463, package_store (1032246 bytes, both times).

The last three are one session's checks, running together; the first is another person's. All were run again on the same node. All four passed (the last at 22:18:06Z). So the files were wrong for a moment, not for the inputs.

What else was true then. A wave of 86 people's jobs started within ten minutes. The node's free disk fell from 1,203 to 664 GiB and reached its floor at 22:05Z; the freer made one large pass at 21:52:32 to 21:53:20Z. Kept memory passed the offer in 21 of 120 samples of the half hour (highest 117%), and t_sched_grow_total rose from about 25 to 67 and then 125 per ten minutes. No job ended for memory.

What I read in the code (verified by me).

  1. The refusal records only the SIZE of each handed file before and after (crates/t-cache/src/cargo/wrapper/run.rs, Handed::of and file). A file replaced by another of the same size, or emptied and rewritten, reads the same as an untouched one. That is why these four lines cannot tell us what happened.
  2. After every run that returned, passing ones too, the wrapper asks Request::Again (wrapper/slot.rs, the loop in the slot's run). Where a process of the slot was killed for memory (hit_its_limit: oom_kill > 0, src/node/slots.rs), the compile runs again in a new slot and writes its outputs again, while dependents compiled against the first outputs may already be running.
  3. A failed placement removes what it placed by NAME (unplace, src/node/daemon/place.rs), not the inode it placed.

What a second reader concluded (a read-only pass over 9faf6c61; I have not verified each citation). The freer, flattening a session's build and hardlinks are ruled out as long as holds are kept (snapshots.rs:830-873, made.rs:353-358, daemon/place.rs:41 and 125-138, depth.rs:142-163, cas/copy.rs:108-131). The best fit is the path where one job compiles a crate and others join it: a joiner gets the holder's .rmeta early and announces it to cargo (daemon/lookup.rs:178-182, 254-280) and the final entry later (189-196). Point 2 above then explains the E0460. The three E0463 are NOT explained for container jobs: by 632265aa's findings E0463 means rustc found the handed file empty, and the only path found that makes a handed name absent is unplace followed by the retry after a freer pass (conn.rs:233-241).

What cannot be had any more. The four jobs' directories are gone from the node, the worker's log of those minutes has rotated, and no counter says how often a slot's compile ran again or a placement was undone.

Proposed, in this order.

  1. Make the next one readable: the refusal records each handed file's inode, ctime and content hash as the compile starts and as it fails, and two counters say how often a compile ran again after its slot's limit and how often a placement was undone. Small, in the wrapper and the daemon.
  2. The invariant I think is missing: a crate file in a job's /target, once announced to cargo, never changes or disappears while that job runs. A compile that passed is not run again over its own outputs; a failed placement removes only what it placed.

Slots and the wrapper's slot loop are yours, so I commission nothing for 2 without your word. I would take 1, but I cannot land anything with a whole check set while t's test checks are refused on testing (issue #62).

A fifth job, with no disk squeeze (08:11Z 11-14, on 67588367)

08:11:22 ERROR t::server::nodes::history: the compiler cache failed the job: refused: the compiler couldn't find crate `video_editor` cargo handed it (/target/debug/deps/libvideo_editor-ad3913b91a3d650c.rlib, 37574154 bytes as the compile started, 37574154 bytes now): error[E0463]: can't find crate for `video_editor` on t-worker-ci-x86-1 job=j566-78417 check="test" cause="cache_unreachable"
  • j566-78417 is a person's test driver job of run rb1e0d46e95, 08:01:42Z to 08:11:22Z. It ended error. The check ran again at 08:14:27Z and passed.
  • The node had 1,230 to 1,271 GB free and nothing deleting at the time. So the squeeze of 11-13 is not needed for this.
  • The file had the same size as the compile started and after, as in the earlier cases. Size alone cannot say whether the file was replaced, rewritten in place, or untouched and already wrong.
  • Jobs ended with cause cache_unreachable in the last 40 hours: seven. Two are another fault: j546-36793 (22:37Z 11-12) and j546-56152 (01:30Z 11-13) were people's ad-hoc cargo build --release --locked --target-dir … commands, the case of issue #50. The other five are this fault: the four of 21:54Z to 21:57Z 11-13 and j566-78417 today. All seven were people's jobs.

I am taking step 1 of the proposal now, as testing runs whole check sets again: the refusal will keep each handed file's device, inode and times from the one metadata call it already makes as the compile starts, read them again on the refusal path only, say which of the three cases it is, and give the file's content hash as it is then. Nothing is added to a compile that passes. Step 2 stays yours.

Step 1 is on main: 6c438411 (08:26Z 11-14)

  • The refusal keeps each handed file's device, inode, modification and change times from the one metadata call it already made as the compile starts. Nothing is hashed there and a passing compile does nothing new.
  • On a refusal only, it reads the file again and says which case it is, then gives its content hash as the cache names blobs:
    • …, 25 bytes as the compile started, 25 bytes now; the same file, unchanged since the compile started (inode N, modified T, changed T); content blake3 <hex>
    • …; another file now (inode A as the compile started, inode B now); content blake3 <hex>
    • …; the same file rewritten since the compile started (inode N; modified T1, changed T1 as it started, modified T2, changed T2 now); content blake3 <hex>
  • The message still begins "the compiler couldn't find crate … cargo handed it" and ends with the compiler's own diagnostic.
  • It is in the wrapper, so production says this from the next promote of a main at or past 6c438411. The next refusal after that names its case, and the hash can be set beside what the node placed at that path.

Seen beside it and not changed: slot.rs near line 92 names only E0463 where E0786 and E0460 are refused too; the refusal describes the first --extern of a crate name if cargo passes a name twice.

  • 08:39Z: the upgrade to 6c438411 is proven on testing with jobs running. It was deployed over fe81dd07 while 13 jobs with courses ran, the worker re-attached all 13, and the check set under it passed 8 of 8. Nothing more is needed from my side before a promote that carries it.
  • 08:57Z: production serves c6dca088, which carries 6c438411. From now a refusal on production names its case and gives the file's hash.

2026-11-14 13:11Z: the first refusal since the message names its case (6c438411)

One job, a person's test-x86_64 build (j569-84627, run r03012839c3), ended error / cache_unreachable after 14.8 minutes. The server's line, whole:

the compiler cache failed the job: refused: the compiler couldn't find crate `tilolang_tilo` cargo handed it
(/target/debug/deps/libtilolang_tilo-b21b2c5ab298d9c9.rlib, 64117580 bytes as the compile started, 64117580 bytes now;
the same file, unchanged since the compile started (inode 4697623690, modified 2026-11-14T13:02:25.631910347Z,
changed 2026-11-14T13:02:25.631910347Z); content blake3 8241151edf039c58de73c891806aabb3f18596be1694a542f916796394f4de88):
error[E0463]: can't find crate for `tilolang_tilo` on t-worker-ci-x86-1 job=j569-84627 check="test-x86_64"
When What
12:56:51Z the job starts, on 099a17b6
13:02:25.63Z the crate file is written once (modified and changed at the same instant)
13:02:57Z the server of 928644e1 starts; the worker takes that build in place
about 13:11:36Z the dependent's compile starts (its slot ran 3.3 s)
13:11:41Z the refusal; the job's end is taken in
13:11:43Z to 13:14:36Z the job run once more (j570-80615) passes in 2.9 minutes

What it settles for this case, of the three the message can say:

  • Not "another file now" and not "rewritten since the compile started": the file is the same inode with the same times and size through the dependent's compile.
  • So a file that never changed was not the crate its dependent was built against. What was written at 13:02:25Z, by a compile of this job or by a placement from the cache, had the name cargo expects (-b21b2c5ab298d9c9) and other contents than the dependent's metadata names.
  • Its content hash is above. Which cache entry holds that blob, and under which unit's key, I have not read yet; the worker's log of 13:02Z and 13:11Z had turned over when I looked (it keeps about a minute).

Two things about the moment, stated as facts and not as a cause:

  • The file was written under 099a17b6's worker and wrapper, and the dependent compiled under 928644e1's, which the worker took nine minutes earlier. 928644e1 changes which units a command that names packages builds (the family's unify member beside them).
  • Before today's diagnostics there were five such jobs in 24 hours: four in the disk squeeze of 21:54Z to 21:58Z on 11-13 and one at 08:11Z today, away from any restart.

I follow the server's log for the next one, so the worker's lines can be read before they turn over.

13:26Z: what the cache holds for it

  • The refused content is the output of two entries stored at 13:03:52Z and 13:03:53Z, 87 seconds after the file was written: pool, compile, pass, never used, different key0 and key1, one read set. So the job compiled this file itself and stored it; nothing placed it. Unit: package tilolang-tilo, lib, mode build, features ["record"], opt-level 0.
  • Under that file name the cache took 18 entries in four hours with 15 library contents and 15 metadata contents, paired one to one within each entry. That alone is expected: a commit changes the sources and not the -C metadata.
  • The refusal is the direct form: the failing compile was handed --extern tilolang_tilo= that file and rustc said E0463 for that crate itself, not for one it depends on. A 64 MB file that was unchanged, that the same job had just compiled and that the cache took as a passing output, was not a crate rustc would take under that name.
  • What I could not read: which crate was compiling, and the job's log. The job was the family's test-x86_64 build of a person's run; t log finds no check of that name in the run, and neither result_latest nor run_events holds anything for it in that minute.
  • A gap of mine: the message does not name the crate being compiled, nor say whether the handed file opens as an archive with its metadata member. I can add both to the wrapper's message.

13:29Z: the stored file itself

I read the refused content in the server's store (/var/lib/t/cas/82/41151e…, read-only) beside a sibling stored two minutes later under the same file name.

  • Both are normal rlibs with the same layout: symbol table, long names (objects tilolang_tilo-b21b2c5ab298d9c9.tilolang_tilo.f209eaf4f70eda4a-cgu.NN.rcgu.o in both), lib.rmeta (6,654,144 and 6,651,352 bytes, written by rustc 1.97.1 (8bab26f4f 2026-07-14)), lib.rmeta-link, objects.
  • So the refused file was not cut short, not another crate, not another -C metadata and not another compiler's.
  • What is left is the crate's own hash against what the failing compile already held of tilolang_tilo: another build of it reached through a different dependency, or a metadata file of another build beside it. rustc gave no note, and nothing kept says which crate was compiling.

I am having the wrapper's message extended, in crates/t-cache/src/cargo/wrapper/run.rs only: it will name the crate being compiled and say what the refused file's head is. That is my message from 6c438411; it changes nothing about what is refused.

13:39Z: the message says more, on main

b6f0e4df: a refusal now begins with the crate being compiled (from --crate-name) and adds, after the blake3, what the refused file's head is: an archive and its first member, a thin archive, a metadata file, other bytes, empty, or unreadable. The head is read only on a refusal, at most 4 KiB. t's whole check set passed for it on testing. Not on production yet: the wrapper is a file a promote swaps on the node, so I prove an upgrade with running jobs on testing first.

13:58Z: b6f0e4df is proven; it goes with the next promote

  • Both CIs passed b6f0e4df: the forge's run in all three jobs, and t's own run on testing 15 of 15.
  • An upgrade with running jobs holds on testing: the whole check set was asked at 928644e1, b6f0e4df was deployed with 15 job directories on the node, and the worker re-attached 13 jobs with none lost, no "missing field", no error. One test failed in that run, the wave test of #72 at its line 307.
  • I do not promote it on its own: it changes only what a refusal says, and a restart costs every open run a new drive. It is on testing and on main for whoever promotes next.

2026-11-14 15:22Z: a second one, in a CI job, and what the plain E0463 means

15:00:45Z, 2.7 minutes after the 14:58Z promote: job j570-54944, check test of head seq 54,142, started 14:47:01Z under 928644e1 (so the old wrapper's message):

the compiler couldn't find crate mail cargo handed it (/target/debug/deps/libmail-8feb28f16cbb8e36.rmeta, 5411093 bytes as the compile started, 5411093 bytes now; the same file, unchanged since the compile started (inode 18387866390, modified 2026-11-14T15:00:07.274702795Z, changed 2026-11-14T15:00:07.331417575Z); content blake3 f842d97b…8ea8): error[E0463]: can't find crate for mail

The file is the output of one cache entry stored 14:59:10Z by another job (key1 fe2bfde5…2487, lib mail, pass) and was placed here 57 s later. Its bytes are a valid metadata file of crate mail, rustc 1.97.1, right triple, not a proc macro, extra filename -8feb28f16cbb8e36.

The file named in these refusals is the wrong file to look at. In rustc 1.97.1 a crate handed by path gives the plain "can't find crate for x" (no "which … depends on") from intern_stable_crate_id (creader.rs:221, CrateError::NotFound): an earlier, silent load of x during import resolution reserved its crate number and then failed on one of the crates x depends on; the reporting lookup that follows meets the reserved number. Reproduced locally with four tiny crates (z, q on z, mail on q, z rebuilt under the same name, a dependent handed mail's untouched .rmeta): with use mail::m; the compiler says exactly E0463 can't find crate for mail``; with mail used only in an expression it says E0460 "found possibly newer version of crate z which mail depends on".

So the plain E0463s (13:11Z tilolang_tilo, 15:00Z mail, three on 11-13) and the E0460 of 11-13 are one fault: in the job's deps directory a crate below the named one is of another build than its dependents were compiled against. The named file being whole and unchanged is consistent with that.

Both of today's came minutes after a promote, in jobs that started before it and ran across the worker's upgrade. The earlier five did not.

Next, in my file (wrapper/run.rs): on this refusal run the failing command once more with RUSTC_LOG=rustc_metadata=info, bounded, and put the loader's Rejecting via hash line (crate, file, expected and found hash) into the message, so the next one names the crate that is of another build. A diagnostic, to go once the cause is fixed. The open question stays how the other build gets there; the joined compile's early metadata followed by another compile's outputs, after a restart ended the holder's claim, is the candidate I would read first.

2026-11-14 15:39Z: the second ask is on main

b77a95ed and b1b11710 (crates/t-cache/src/cargo/wrapper/run.rs only; whole check set on testing green, run r3e0935d7fa). On the plain E0463 of a handed crate whose file is there and not empty, the wrapper runs the same compile once more with RUSTC_LOG=rustc_metadata=info (one attempt, at most 20 s and 16 MiB of stderr, then killed and reaped) and the refusal ends with what the loader rejected, for example:

…error[E0463]: can't find crate for mail; asked again with its loader's log on, the compiler rejected: crate z (which q depends on) in out/libz-zz.rmeta and out/libz-zz.rlib via hash: expected 0cf2c16c… got 8012ab15…

or "the compiler took the crate" (a state of the moment), "named no rejection", or "could not ask the compiler again". Every other refusal is told as before, and no passing or ordinarily failing compile runs anything more. Not on production yet; the upgrade proof with running jobs is running on testing. It is a diagnostic: it goes once the cause is fixed.

15:57Z: b1b11710 is green on the forge and on testing (r3de76448cc), and a worker upgraded from 4d2ee46f to it on testing at 15:53:44Z re-attached its 14 running jobs; the run they belonged to (r1ce87b9095) ended 8 of 8 with 39 jobs passed and none lost. It can ride with the next promote.

2026-11-14 17:00Z: a third one, 8 minutes after the 16:46Z promote; three restarts of four today

restart (Z) refusal (Z) job started refused crate how its file came to be
13:02:57 13:11:41 j569-84627, a person's test-x86_64 12:56:51 tilolang_tilo (.rlib) compiled by the job 13:02:25, 32 s before the restart
14:58:03 15:00:45 j570-54944, a head's test 14:47:01 mail (.rmeta) placed from the cache 15:00:07, 104 s after it
15:26:46 none in 80 minutes
16:46:25 16:54:27 j572-93547, a person's test 16:42:51 backups (.rlib) compiled by the job 16:45:12, 73 s before the restart

Every one is in a job that started before a promote and ran across the worker's upgrade; every refused file is whole and unchanged. The 16:54Z line (old wrapper, so no second ask yet):

compiling crate contents, the compiler couldn't find crate backups cargo handed it (/target/debug/deps/libbackups-cd1711064b51ef0f.rlib, 18629228 bytes as the compile started, 18629228 bytes now; the same file, unchanged since the compile started (inode 20401105103, modified 2026-11-14T16:45:12.375011041Z, changed 2026-11-14T16:45:12.375011041Z); content blake3 205ae23e…fc75; an archive whose first member is the symbol table): error[E0463]: can't find crate for backups

By what the plain E0463 means (above), a crate below the refused one was another build when the dependent compiled, minutes after the restart, than when the refused crate compiled, just before it. So something replaces a crate file in a running job's deps directory across a restart.

What the worker's log shows for j572-93547 after the restart (worker re-attached 16:46:44.97Z, 60 jobs): two compiles started at 16:46:46 and 16:46:51, one of 66 s and one of 459 s (5.5 GB peak, 678 CPU seconds); when the long one ended at 16:54:25 nineteen compiles of 0.1 to 0.3 s followed within two seconds, the refused one among them. The 15:00Z job has the same mark: its two long compiles started 19 s after that restart's re-attach. Across all jobs 352 compile slots started in the 40 s after the 16:46Z re-attach.

A lead I have not shown: before the restart the job's compile of that unit was joined to another job's, the holder's metadata was placed and announced (take_metadata), and dependents compiled against it; the restart ended the claim, the wrapper asked again, found no holder (join: Watched::Free, then Found::Run) and compiled the unit itself, writing other metadata over the announced file. What it lacks is why two builds under one key would differ. slots.again is not it: it answers nothing for a slot the new daemon does not know.

From 16:46Z the wrapper asks the compiler again on such a refusal, so the next one in a job started after that names the crate below, its files and both hashes.

18:42Z, the one comparison I can make: I hold the worker's log across two restarts. Compile slots that started within 40 s of the worker's re-attach: at 16:46Z (a refusal followed) 728 in 11 jobs, four of them 120 s or longer, in two jobs: the refused job's 459 s compile and three in j572-92948 (201, 175 and 127 s; that job: j572-92948 | test | ci | pass | - | 16:39:46 | 16:57:35); at 17:09Z (no refusal followed) 158 in 12 jobs and none of 120 s or longer. Also checked and empty: the read sets stored with the refused mail and backups entries name sources only (96 and 18 .rs files, no crate file of the deps directory), so crates below enter a key only through the bytes of the directly handed files; and neither entries nor entries_log holds two builds of one key to compare (one put a key, and no key under both trusts for these crates in twelve hours).

2026-11-15 23:14Z: one more, 17.5 hours after the last restart, and the second ask names no hash

Since the table above:

restart (Z) refusal (Z) job started refused crate how its file came to be
19:12:11 11-14 none
20:49 11-14 none
00:06 11-15 none
05:45:08 11-15 23:13:55, 17 h 29 min later j578-25355, a person's cargo build -p agent --release 22:51:51 tilo_agent (.rlib) compiled by the job itself, written 22:57:13, 16.5 minutes before

So four restarts in a row brought none, and this one came with no restart near it: production 1b22804f, the node fully busy (people's jobs on 136 of 154 cores in that minute), no squeeze on the disk (1,230 GiB free).

The ending, from the server's log (saved, with the worker's log of the job):

compiling crate `tilo_agent`, the compiler couldn't find crate `tilo_agent` cargo handed it
(/target/release/deps/libtilo_agent-98cea62d9d77b279.rlib, 19221270 bytes as the compile started, 19221270 bytes now;
the same file, unchanged since the compile started (inode 14764083701, modified 22:57:13.007Z, changed 22:57:13.240Z);
content blake3 dbf4de56…; an archive whose first member is the symbol table): error[E0463]: can't find crate for `tilo_agent`;
asked again with its loader's log on, the compiler rejected: crate `serde_derive` (which `serde` depends on) in
…/libserde_derive-ebbe3101b41187ff.so via proc macro: expected false got true; … `zeroize_derive` … `der_derive` …
`curve25519_dalek_derive` … `zerocopy_derive` … `hax_lib_macros` … via proc macro: expected false got true

What it shows and what it does not:

  • All six rejections are the locator's ordinary first look at a proc-macro dependency: it starts with is_proc_macro = false, turns the .so away, then loads it as a proc macro. a24aac0c leaves out the other direction ("expected true got false") only. So the second ask names no rejection by hash: no other build of a crate below was turned away when the compiler was asked again a moment later. That is new against the three of 11-14, which the message could not yet read.
  • The job (worker's log, 481 lines): 477 compile slots, every one found=false, a release build with nothing in the cache, so every file in its /target was written by this job. The library's own compile ended 22:57:13.19Z (30 s). A 591 s compile with a peak of 9.6 GB ended 23:13:52.34Z after waiting 444 s for its slot. The failing unit, the package's bin with the same crate name, ran 0.83 s and ended 23:13:54.68Z.
  • So this is neither a placement from the cache, nor a restart, nor a file that changed: one job, its own files, sixteen minutes old, and the compiler did not find a crate at the first ask.

Open, and how I go on: the check's log (t ran the erred check again; a step of mine saves the log when that run ends) should say whether the second ask loaded the crate, which would make the first failure a passing one in the job's own directory, not a wrong file. And the message needs one more cut, mine to make: leave out "expected false got true" as well, and say "named no rejection" when nothing is left.

23:35Z, the same check run again. t ran the erred check once more in the same run (raf5099ab0c): job j578-26180 passed, Finished release profile … in 19m 53s, 961 of its 1,915 compiles from the cache (the 953 the refused job had stored among them) and 953 stored. So the inputs and the cache's entries were sound, and the failure belonged to the first job's own directory at that moment, as on 11-14 at 13:11Z and 16:54Z.

02:05:54Z 11-16: once more, 55 minutes after a restart, in a job that ran alone in its files. Production 8bd4b1f2 (server and worker pod both new since 01:10Z and 01:14Z).

job j580-7815, test/tilo-session-client, people's (run re2221ab15e, quinten), width 6, launched 02:00:27Z
refused compiling tilo_session_client: can't find crate for tilo_session_core, plain E0463
the file /target/debug/deps/libtilo_session_core-4ff9ae93bdf04e61.rlib, 11,049,382 bytes, same inode, modified and changed 02:00:37.7Z, unchanged since the compile started
asked again six lines, all via proc macro: expected false got true: no rejection by hash, as at 23:13Z
cause given cache_unreachable; t asked the check again (j580-8070), the asker stopped the run a minute later

What the worker's log adds (saved, refused-0205-worker.log): the job ran eight compiles of its own, all found=false. Seven were short. One took 246.6 s with four tokens and a peak of 6.3 GB, after waiting 65 s for its slot, and ended 02:05:48.45Z. The two compiles that failed started about 02:05:51Z and ended 02:05:54.2Z after 3.2 s each. So the picture is the same as at 23:13Z on 11-15 (a 591 s compile with a 9.6 GB peak ended 3 s before the refusal): both times the refused compile started within three seconds of the end of a multi-gigabyte, minutes-long compile in the same job, and the crate file it could not find had been lying there unchanged for minutes. The file was in place before any compile of this job started (02:00:37.7Z is the second its first slot began), so it came with the build directory or a placement, not from the long compile.

What I could not read: which crate the long compile was, and what cargo printed. The job's directory was gone six minutes after its end, the stopped run's check answers cancelled with no log, and the slot lines' unit is not sha256(ident) of t.entries. From now a step of mine (refusal-capture.sh) follows the server's log and copies the job's out.stderr, compile-reads and observed and both pods' logs in the second the line appears.

Six jobs ended cache_unreachable in 48 hours: four on 11-14 (08:11Z, 13:11Z, 15:00Z, 16:54Z), 23:13Z on 11-15 and this one.

03:00Z 11-16: what the code says about the seconds after a compile (read on main 8d2d89b1), and one thing both cases share.

Both saved worker logs hold exactly one line moving a wrapper out of its slot: write <pid> to …/own/cgroup.procs: No such process, and both times it is the refused job's, in the 10 ms after the refused compile's slot ended (23:13:54.687Z on 11-15, 02:05:54.219Z today). Read in the code it is a result, not a cause: a wrapper that refuses leaves without Done (slot.rs:111-113, compile.rs:81, entry.rs:152), and release() then writes a pid that is gone (slots.rs:1598-1605). The check that should skip that error never matches, because write_existing wraps it through named() and the wrapped error carries no OS error number (cgroup.rs:229-235, 1557-1560). Small, mine to fix with the message's cut.

What touches a job's target directory, by the code:

  • After a successful compile: nothing writes there on Linux. store() reads and stats the outputs, the node's put copies or clones them into its store and leaves the job's files alone (put.rs:103-212, cas/put.rs:363-415), and nothing works on them after the wrapper has returned to cargo.
  • A placement on a hit is a copy made under /target/.t-placing and renamed over the destination (cas/place.rs:213-219): old file or new, never none. Only the asking unit's own outputs are placed.
  • No memory limit is lowered when a slot ends (cgroup.rs:791-818), and a slot's end kills nothing (cgroup.rs:1142).
  • The one window found: a placement that fails part way unlinks what it had already renamed into place (daemon/place.rs:102-105, 367-373). If that unit's .rmeta had been announced before (lookup.rs:254-274), dependents cargo started on it can lose the file. It concerns the failing unit's own outputs only, and I cannot tie it to either job.

So the long compile's end is not, by the code, a moment when files move. What stays unexplained is why a compile fails at the first ask and names no rejection at the second, three seconds after such a compile, twice. The next capture (refusal-capture.sh, armed since 02:16Z) should give cargo's output and the job's compile reads, which say which crate the long compile was and whether its metadata had come from another job's claim while this job waited 65 s in that claim's line before compiling it itself.

03:05Z 11-16: what the long compile before each refusal has in common: it had waited on another job's claim, then compiled the unit itself.

The slot line's waited_ms counts the time a compile stood on another job's claim (conn.waited, node/daemon/lookup.rs join), queued_ms the time for its slot. In the two saved worker logs, 6,142 slot lines, three compiles ran themselves (found=false) after standing 5 s or more on a claim:

ended (UTC) job check compile stood on a claim then
11-15 23:13:52 j578-25355 cargo build -p agent --release, people 591 s, 9.6 GB 444 s refused 3 s later (a dependent, 0.8 s)
11-16 01:37:33 j580-1465 test, CI 449 s 352 s nothing: the job passed
11-16 02:05:48 j580-7815 test/tilo-session-client, people 247 s, 6.3 GB 65 s refused 3 s later (two dependents, 3.2 s each)

So both refusals follow such a compile, and two of the three such compiles are followed by a refusal. In today's case the holder was j580-7471 (the same unit, 275 s, ended 02:02:26Z); the waiter left its line at 02:01:42Z, 44 s before the holder ended, and compiled the unit itself.

What the code rules out: a waiter does not take a holder's metadata on the first key alone. Claims::watched hands a holder's step only to a watch whose own keys hold the step's key1 (jobs/claims.rs, if keys.contains(&step.key1())), and tells the others the holder's read set instead. So a waiter whose files differ is told the read set, finds its key differs and compiles itself, which is what the 65 s and the 444 s look like.

What is open: why the unit's dependents then fail at the first ask. The dependents that were already in the job's directory (today tilo_session_core, in place since the job's first second) were not rewritten after the waiter's own compile, so either they do not depend on that unit or their re-ask was a hit on the same bytes (a placement leaves a file with the same hash alone, daemon/place.rs:293-305). The capture step should show, from the job's compile reads, which unit the long compile was and what each dependent was keyed on.

08:25Z 11-16: the two cuts are on main (0dd1b888, 95b08710), not on production yet

  • The message (crates/t-cache/src/cargo/wrapper/run.rs, rejected): Rejecting via proc macro: expected false got true is left out as the other proc-macro line is. Both refusals with the diagnostic on (23:13:55Z on 11-15, 02:05:54Z today) listed six of them and nothing else; from the build that carries this such a refusal ends "the compiler named no rejection", or "took the crate".
  • The warning (src/node/cgroup.rs, src/node/slots.rs): cgroup::move_process moves a process into a cgroup and answers a process gone meanwhile (ESRCH) apart from an error; Slots::release and the node's start use it. write_existing names its error through named, which keeps no error number, so the skip in release never matched and each refusal was followed by "moving a wrapper out of its slot: … No such process". That line was a result of the refusal, never a cause.
  • Whole check set on testing green (run rc55109322a), forge workflow green, testing's image built. They ride the next promote; I do not promote them alone.

The cause of the refusals themselves is as open as above: no refusal since 02:05:54Z, and the capture step is still armed.

16:45Z 11-17: a fourth refusal, and what the times and the cache's rows show

Job j603-10955 (a person's test-x86_64/tilo-agent-session, run r8ebab3caf5, production f5147065, two hours after its start, 1,283 GB of disk free: no squeeze) ended error | cache_unreachable at 16:45:17Z: compiling crate it, E0463 for tilo_agent; asked again, the loader rejected tilo_ui for three dependents (tilo_app, tilo_desktop_surface, tilo_feedback_transport) "via hash: expected 8471a484… got 55bb4d27…" in libtilo_ui-f4f1add1974eae79.rmeta and .rlib.

In order (the worker's slot lines, t.entries, t.job_history):

time (Z) what
16:30:57 run r58be5b61e2 asked; its job j603-10885
16:31:39 run r8ebab3caf5 asked by the same session, same check; its job j603-10955
16:35:25 j603-10885 starts compiling tilo_ui (the worker's unit 3c12182b)
16:37:31 j603-10955 asks for tilo_ui and stands on j603-10885's claim (slot line waited_ms=99948 queued_ms=5)
16:37:41 j603-10955's cargo starts tilo_app, a dependent of tilo_ui, though its own compile of tilo_ui has not begun: tilo_ui's metadata is in its directory. tilo_app stands 25.6 s on j603-10885's claim
16:38:07 j603-10885 stores tilo_app (libtilo_app-1195715b7692414d, key0 7f4e66a94cc3494c, key1 1c2d0610…); j603-10955, of the same key0 and another key1, compiles tilo_app itself
16:39:09 j603-10955 stores its tilo_app (key0 7f4e66a94cc3494c, key1 7c7722e1…, 62.2 s)
16:39:11.49 j603-10885 is cancelled (its run was stopped) 225.9 s into tilo_ui; it stores no tilo_ui
16:39:11.5 j603-10955 is told to run tilo_ui itself (351.5 s); four more of its compiles start in the next 47 s
16:45:03 its own tilo_ui ends; stored 16:45:04 (key0 3e7d4022…, key1 3b211a51…)
16:45:07 it starts compiling; refused at 16:45:16

Reading. Both tilo_app entries have one key0, so both were compiled against the same tilo_ui metadata: the holder's, which the claim handed to the job in line (Reply::Metadata: the node places it, src/node/daemon/lookup.rs:286-304; the wrapper announces it to cargo, crates/t-cache/src/cargo/wrapper/conn.rs:111-114). The holder never finished. Told Run (find.rs:365), the job compiled tilo_ui itself and its compiler wrote other metadata over the one its dependents were built on (55bb4d27 where they expect 8471a484). What E0463 names (tilo_agent) is not the crate at fault.

Not explained. Why the job's own compile gives another hash than the holder's. A metadata step goes only to a waiter whose keys hold the step's key1, so by the keys both compiled the same inputs: either the compile is not reproducible, or the two differ in something the key does not hold. What the cache shows: in 24 h it kept one key1 of tilo-ui and two of tilo-app under two trusts (two compiles of identical keyed inputs), and all three pairs have identical output files. The two runs do differ somewhere: tilo_app's key1 differs between them.

The old signature is not enough. On 11-17 (00:00 to 16:55Z) 801 of 801,058 slot lines are compiles that stood 5 s or more on another job's claim and then ran themselves; one job was refused. It takes all three: metadata taken from the holder, the holder gone before its library, and other metadata from the job's own compile.

Next (one log line, no change on the wire, nothing a job does changes). Where the node places a holder's metadata for a job in line (Inner::take_metadata, src/node/daemon/lookup.rs) it now says so, with the waiting job, the holder's node, the file's name and content hash, the waiter's key0 and the step's key1: landed on main as 9d09529f at 17:14:13Z (whole check set on testing green, run rab329f8271: 8 passed, 0 failed, 0 errors). It is live on production since the 18:30:03Z promote of 2885a521: sixteen such lines in the first ninety seconds after the worker re-attached, so a holder's metadata is handed to jobs in line all the time and nearly always ends well. At the next case the line gives the holder's metadata hash and key1; t.entries gives the key1 and the metadata hash the waiter's own compile stored. The same key1 with another hash is a compile that is not reproducible; another key1 is a step handed under a key that does not describe the waiter's compile. I propose no fix before that. To weigh then: end such a job at the long compile's end under this as its named cause (it cannot pass, and today it runs on to a misleading E0463), or let a cancelled holder finish a compile others took metadata from.

t ran the check again in the same run (j603-12636). The capture step copied nothing: the job's directory was gone within seconds of its end.

18:46Z 11-17: c0f2a058 on main (yours) takes the first of the two ways I listed, and carries the diagnostic with it. The node keeps what a job announced from another job's claim and ends the job at the compile that writes other metadata over it, as metadata_replaced, with both hashes and both key1s, and the check is asked again. Once it is on production the next case says by itself which of the two causes it is: the same key1 with another hash is a compile that is not reproducible, another key1 is a step handed under a key that does not describe the waiter's compile. What stays open here is only that: why two compiles of one key differ. I will add the first metadata_replaced end to this issue and close it if the answer is in the keys.

01:25Z 11-18: the next case came across a worker's upgrade, and was told cache_unreachable, not metadata_replaced

The job. j605-532, test-x86_64/tilo-agent-session of probe run r34481520a9: started 01:15:33Z on 7710cc0d (which has c0f2a058), ended 01:25:58Z on ab189001 as error | cache_unreachable. It is the one job of t's own that erred across your 01:21:32Z promote (my check ten minutes after: 54 other jobs that ran across it ended on their own).

What it was handed (my line from 9d09529f, "a holder's metadata is placed for a job in line", all with holder node t-worker-ci-x86-1):

time file key0 key1
01:19:27.80Z libtilo_ui-7f994c480d8722bf.rmeta 8c3fd7c1dc41… c8c8e69…
01:21:16.61Z libtilo_ui-d31143600bc07638.rmeta (hash a9121f3ceb49…) dd579c0e994a… 0322064…
01:21:16.63Z to 01:21:17.39Z tilo_runner_native, tilo_emoji_catalogue, tilo_feedback_transport

Then the upgrade. Server start 01:21:32Z; the worker "fetched the server's build" at 01:21:42.67Z and "re-attached to the jobs on disk jobs=58" at 01:21:51.39Z. From 01:21:57Z the job's slot lines carry the new daemon's slot ids, and about 35 of its compiles end within nine seconds. At 01:25:58Z rustc: compiling it, can't find crate tilo_agent; with its loader's log on: "crate tilo_ui (which tilo_app depends on) in libtilo_ui-d31143600bc07638.rmeta and .rlib via hash: expected 0e1b1289… got a942919e…", and five more candidates of tilo_ui. The same signature as 16:45Z: the file it had been handed 16 seconds before the restart held other metadata at the end.

Why c0f2a058 did not name it. What a job announced is kept in the daemon's memory alone: Inner::announced (src/node/daemon/inner.rs:96) begins empty in each daemon (handle.rs:83), and nothing in src/node/attach.rs fills it for the jobs a worker re-attaches. Inner::replaced (put.rs:115) then finds no entry for the job and says nothing. What a compile replaced is kept with the job (run-t/metadata-replaced, src/cargo/job.rs: "kept in the job's directory, not in the daemon's memory"); what it announced is not. So across an in-place upgrade the check of the invariant is blind for every job that announced before it, and an upgrade is when holders go: the new daemon knows no claim the old one held, a job in line asks again, is told to run and compiles the unit itself while the holder's compile goes on too.

What I propose, and will commission unless you take it or object (one developer of mine builds locally at a time; the next slot is this): what a job announces is written with the job as it is announced, beside run-t/metadata-replaced, and read back for the jobs a worker re-attaches, so replaced sees it in the new daemon; a test that re-attaches a job across a daemon's restart and then has its compile write other metadata, red on main. It changes a job's files on the node, so it gets the upgrade proof before any promote of mine. It does not touch the other question, which stays open: why the job's own compile of a unit gives other metadata than the holder's.

02:08Z 11-18: that fix is on main, da23690a (not on production). Each announcement is appended, as it is made, to metadata-announced at the top of the job's directory (<data>/jobs/<job>/metadata-announced, beside compile-reads), one JSON record a line (cargo::job::Announcement: path, hash, key1, unit, holder), written by the worker's cache daemon in Inner::announce_metadata. It is not under run-t, which is bound into the job: the job neither sees nor can write it. A daemon that holds nothing of a job reads the file in Daemon::serve_job before it binds the job's socket (Inner::read_announced), so no compile of a re-attached job reaches the new daemon before it holds what the old one announced. A file or a line that does not read is one error line and the rest counts; a job from before this build has no file and is served as before. No wire type, nothing a job is told, nothing in the server. Five tests; the one that announces, restarts the daemon and then has the compile write other metadata is red without the read-back ("the compile is refused: Ok"). The job directories' fixture gains the file (format b8a1ec5908b86ed4). t's whole check set green on testing for it on 84cb9365.

It adds a file to a job's directory, so I run the upgrade proof for da23690a on testing before I promote (jobs running there across the deploy must all re-attach). Then one promote of main's head for this and #93's change together, on the conditions written in #93.

02:19Z 11-18: the upgrade proof holds for da23690a (testing). A whole check set forced with a nonce ran at 84cb9365; with 18 job directories on the node, all with a course, da23690a was deployed: the worker "fetched the server's build" at 02:19:50Z and "re-attached to the jobs on disk jobs=14" at 02:19:51Z, none reaped as unattachable, no "missing field", no ERROR line, no panic; the run across it passed its 8 checks (32 jobs, all pass). Forge run on da23690a pending; then the promote, behind the gates written in #93.

Production, 9faf6c61 (the build before your 22:08Z promote). The wrapper, slot and placement files named below are unchanged in 6ebaa239, so this stands for the build production runs now. Nothing was changed on production; no code of mine is in flight. **What happened.** No job had ended this way in the 5 h 20 min since the 16:32Z restart. Then four people's jobs ended `cache_unreachable` within three minutes, 21:54:49 to 21:57:51Z 11-13: - j559-80704, `cargo build -p tilo-web-desktop` for wasm (started 21:49:32): E0463, can't find crate `tilo_delivery_protocol` (the `.rmeta` cargo handed it, 627071 bytes as the compile started and now). - j559-80090, test/ebook (21:40:48): E0463, `runtime_collab` (9820695 bytes, both times). - j559-80075, test/contacts (21:40:35): E0460, "found possibly newer version of crate `tilo_dav` which `cloud_source_dav` depends on". - j559-80080, test/notes (21:40:35): E0463, `package_store` (1032246 bytes, both times). The last three are one session's checks, running together; the first is another person's. All were run again on the same node. All four passed (the last at 22:18:06Z). So the files were wrong for a moment, not for the inputs. **What else was true then.** A wave of 86 people's jobs started within ten minutes. The node's free disk fell from 1,203 to 664 GiB and reached its floor at 22:05Z; the freer made one large pass at 21:52:32 to 21:53:20Z. Kept memory passed the offer in 21 of 120 samples of the half hour (highest 117%), and `t_sched_grow_total` rose from about 25 to 67 and then 125 per ten minutes. No job ended for memory. **What I read in the code (verified by me).** 1. The refusal records only the SIZE of each handed file before and after (crates/t-cache/src/cargo/wrapper/run.rs, `Handed::of` and `file`). A file replaced by another of the same size, or emptied and rewritten, reads the same as an untouched one. That is why these four lines cannot tell us what happened. 2. After every run that returned, passing ones too, the wrapper asks `Request::Again` (wrapper/slot.rs, the loop in the slot's run). Where a process of the slot was killed for memory (`hit_its_limit`: `oom_kill > 0`, src/node/slots.rs), the compile runs again in a new slot and writes its outputs again, while dependents compiled against the first outputs may already be running. 3. A failed placement removes what it placed by NAME (`unplace`, src/node/daemon/place.rs), not the inode it placed. **What a second reader concluded (a read-only pass over 9faf6c61; I have not verified each citation).** The freer, flattening a session's build and hardlinks are ruled out as long as holds are kept (snapshots.rs:830-873, made.rs:353-358, daemon/place.rs:41 and 125-138, depth.rs:142-163, cas/copy.rs:108-131). The best fit is the path where one job compiles a crate and others join it: a joiner gets the holder's `.rmeta` early and announces it to cargo (daemon/lookup.rs:178-182, 254-280) and the final entry later (189-196). Point 2 above then explains the E0460. The three E0463 are NOT explained for container jobs: by 632265aa's findings E0463 means rustc found the handed file empty, and the only path found that makes a handed name absent is `unplace` followed by the retry after a freer pass (conn.rs:233-241). **What cannot be had any more.** The four jobs' directories are gone from the node, the worker's log of those minutes has rotated, and no counter says how often a slot's compile ran again or a placement was undone. **Proposed, in this order.** 1. Make the next one readable: the refusal records each handed file's inode, ctime and content hash as the compile starts and as it fails, and two counters say how often a compile ran again after its slot's limit and how often a placement was undone. Small, in the wrapper and the daemon. 2. The invariant I think is missing: a crate file in a job's `/target`, once announced to cargo, never changes or disappears while that job runs. A compile that passed is not run again over its own outputs; a failed placement removes only what it placed. Slots and the wrapper's slot loop are yours, so I commission nothing for 2 without your word. I would take 1, but I cannot land anything with a whole check set while t's test checks are refused on testing (issue #62). ## A fifth job, with no disk squeeze (08:11Z 11-14, on 67588367) ``` 08:11:22 ERROR t::server::nodes::history: the compiler cache failed the job: refused: the compiler couldn't find crate `video_editor` cargo handed it (/target/debug/deps/libvideo_editor-ad3913b91a3d650c.rlib, 37574154 bytes as the compile started, 37574154 bytes now): error[E0463]: can't find crate for `video_editor` on t-worker-ci-x86-1 job=j566-78417 check="test" cause="cache_unreachable" ``` - j566-78417 is a person's `test` driver job of run rb1e0d46e95, 08:01:42Z to 08:11:22Z. It ended `error`. The check ran again at 08:14:27Z and passed. - The node had 1,230 to 1,271 GB free and nothing deleting at the time. So the squeeze of 11-13 is not needed for this. - The file had the same size as the compile started and after, as in the earlier cases. Size alone cannot say whether the file was replaced, rewritten in place, or untouched and already wrong. - Jobs ended with cause `cache_unreachable` in the last 40 hours: seven. Two are another fault: j546-36793 (22:37Z 11-12) and j546-56152 (01:30Z 11-13) were people's ad-hoc `cargo build --release --locked --target-dir …` commands, the case of issue #50. The other five are this fault: the four of 21:54Z to 21:57Z 11-13 and j566-78417 today. All seven were people's jobs. **I am taking step 1 of the proposal now**, as testing runs whole check sets again: the refusal will keep each handed file's device, inode and times from the one `metadata` call it already makes as the compile starts, read them again on the refusal path only, say which of the three cases it is, and give the file's content hash as it is then. Nothing is added to a compile that passes. Step 2 stays yours. ## Step 1 is on main: 6c438411 (08:26Z 11-14) - The refusal keeps each handed file's device, inode, modification and change times from the one `metadata` call it already made as the compile starts. Nothing is hashed there and a passing compile does nothing new. - On a refusal only, it reads the file again and says which case it is, then gives its content hash as the cache names blobs: - `…, 25 bytes as the compile started, 25 bytes now; the same file, unchanged since the compile started (inode N, modified T, changed T); content blake3 <hex>` - `…; another file now (inode A as the compile started, inode B now); content blake3 <hex>` - `…; the same file rewritten since the compile started (inode N; modified T1, changed T1 as it started, modified T2, changed T2 now); content blake3 <hex>` - The message still begins "the compiler couldn't find crate `…` cargo handed it" and ends with the compiler's own diagnostic. - It is in the wrapper, so production says this from the next promote of a main at or past 6c438411. The next refusal after that names its case, and the hash can be set beside what the node placed at that path. Seen beside it and not changed: `slot.rs` near line 92 names only E0463 where E0786 and E0460 are refused too; the refusal describes the first `--extern` of a crate name if cargo passes a name twice. - 08:39Z: the upgrade to 6c438411 is proven on testing with jobs running. It was deployed over fe81dd07 while 13 jobs with courses ran, the worker re-attached all 13, and the check set under it passed 8 of 8. Nothing more is needed from my side before a promote that carries it. - 08:57Z: production serves c6dca088, which carries 6c438411. From now a refusal on production names its case and gives the file's hash. ## 2026-11-14 13:11Z: the first refusal since the message names its case (6c438411) One job, a person's `test-x86_64` build (j569-84627, run r03012839c3), ended `error` / `cache_unreachable` after 14.8 minutes. The server's line, whole: ``` the compiler cache failed the job: refused: the compiler couldn't find crate `tilolang_tilo` cargo handed it (/target/debug/deps/libtilolang_tilo-b21b2c5ab298d9c9.rlib, 64117580 bytes as the compile started, 64117580 bytes now; the same file, unchanged since the compile started (inode 4697623690, modified 2026-11-14T13:02:25.631910347Z, changed 2026-11-14T13:02:25.631910347Z); content blake3 8241151edf039c58de73c891806aabb3f18596be1694a542f916796394f4de88): error[E0463]: can't find crate for `tilolang_tilo` on t-worker-ci-x86-1 job=j569-84627 check="test-x86_64" ``` | When | What | |---|---| | 12:56:51Z | the job starts, on 099a17b6 | | 13:02:25.63Z | the crate file is written once (modified and changed at the same instant) | | 13:02:57Z | the server of 928644e1 starts; the worker takes that build in place | | about 13:11:36Z | the dependent's compile starts (its slot ran 3.3 s) | | 13:11:41Z | the refusal; the job's end is taken in | | 13:11:43Z to 13:14:36Z | the job run once more (j570-80615) passes in 2.9 minutes | What it settles for this case, of the three the message can say: - Not "another file now" and not "rewritten since the compile started": the file is the same inode with the same times and size through the dependent's compile. - So a file that never changed was not the crate its dependent was built against. What was written at 13:02:25Z, by a compile of this job or by a placement from the cache, had the name cargo expects (`-b21b2c5ab298d9c9`) and other contents than the dependent's metadata names. - Its content hash is above. Which cache entry holds that blob, and under which unit's key, I have not read yet; the worker's log of 13:02Z and 13:11Z had turned over when I looked (it keeps about a minute). Two things about the moment, stated as facts and not as a cause: - The file was written under 099a17b6's worker and wrapper, and the dependent compiled under 928644e1's, which the worker took nine minutes earlier. 928644e1 changes which units a command that names packages builds (the family's unify member beside them). - Before today's diagnostics there were five such jobs in 24 hours: four in the disk squeeze of 21:54Z to 21:58Z on 11-13 and one at 08:11Z today, away from any restart. I follow the server's log for the next one, so the worker's lines can be read before they turn over. ### 13:26Z: what the cache holds for it - The refused content is the output of two entries stored at 13:03:52Z and 13:03:53Z, 87 seconds after the file was written: `pool`, compile, pass, never used, different key0 and key1, one read set. So the job compiled this file itself and stored it; nothing placed it. Unit: package `tilolang-tilo`, lib, mode build, features `["record"]`, opt-level 0. - Under that file name the cache took 18 entries in four hours with 15 library contents and 15 metadata contents, paired one to one within each entry. That alone is expected: a commit changes the sources and not the `-C metadata`. - The refusal is the direct form: the failing compile was handed `--extern tilolang_tilo=` that file and rustc said E0463 for that crate itself, not for one it depends on. A 64 MB file that was unchanged, that the same job had just compiled and that the cache took as a passing output, was not a crate rustc would take under that name. - What I could not read: which crate was compiling, and the job's log. The job was the family's `test-x86_64` build of a person's run; `t log` finds no check of that name in the run, and neither `result_latest` nor `run_events` holds anything for it in that minute. - A gap of mine: the message does not name the crate being compiled, nor say whether the handed file opens as an archive with its metadata member. I can add both to the wrapper's message. ### 13:29Z: the stored file itself I read the refused content in the server's store (`/var/lib/t/cas/82/41151e…`, read-only) beside a sibling stored two minutes later under the same file name. - Both are normal rlibs with the same layout: symbol table, long names (objects `tilolang_tilo-b21b2c5ab298d9c9.tilolang_tilo.f209eaf4f70eda4a-cgu.NN.rcgu.o` in both), `lib.rmeta` (6,654,144 and 6,651,352 bytes, written by rustc 1.97.1 (8bab26f4f 2026-07-14)), `lib.rmeta-link`, objects. - So the refused file was not cut short, not another crate, not another `-C metadata` and not another compiler's. - What is left is the crate's own hash against what the failing compile already held of `tilolang_tilo`: another build of it reached through a different dependency, or a metadata file of another build beside it. rustc gave no note, and nothing kept says which crate was compiling. I am having the wrapper's message extended, in `crates/t-cache/src/cargo/wrapper/run.rs` only: it will name the crate being compiled and say what the refused file's head is. That is my message from 6c438411; it changes nothing about what is refused. ### 13:39Z: the message says more, on main b6f0e4df: a refusal now begins with the crate being compiled (from `--crate-name`) and adds, after the blake3, what the refused file's head is: an archive and its first member, a thin archive, a metadata file, other bytes, empty, or unreadable. The head is read only on a refusal, at most 4 KiB. t's whole check set passed for it on testing. Not on production yet: the wrapper is a file a promote swaps on the node, so I prove an upgrade with running jobs on testing first. ### 13:58Z: b6f0e4df is proven; it goes with the next promote - Both CIs passed b6f0e4df: the forge's run in all three jobs, and t's own run on testing 15 of 15. - An upgrade with running jobs holds on testing: the whole check set was asked at 928644e1, b6f0e4df was deployed with 15 job directories on the node, and the worker re-attached 13 jobs with none lost, no "missing field", no error. One test failed in that run, the wave test of #72 at its line 307. - I do not promote it on its own: it changes only what a refusal says, and a restart costs every open run a new drive. It is on testing and on main for whoever promotes next. ## 2026-11-14 15:22Z: a second one, in a CI job, and what the plain E0463 means **15:00:45Z**, 2.7 minutes after the 14:58Z promote: job j570-54944, check `test` of head seq 54,142, started 14:47:01Z under 928644e1 (so the old wrapper's message): > the compiler couldn't find crate `mail` cargo handed it (/target/debug/deps/libmail-8feb28f16cbb8e36.rmeta, 5411093 bytes as the compile started, 5411093 bytes now; the same file, unchanged since the compile started (inode 18387866390, modified 2026-11-14T15:00:07.274702795Z, changed 2026-11-14T15:00:07.331417575Z); content blake3 f842d97b…8ea8): error[E0463]: can't find crate for `mail` The file is the output of one cache entry stored 14:59:10Z by another job (key1 fe2bfde5…2487, lib `mail`, pass) and was placed here 57 s later. Its bytes are a valid metadata file of crate `mail`, rustc 1.97.1, right triple, not a proc macro, extra filename `-8feb28f16cbb8e36`. **The file named in these refusals is the wrong file to look at.** In rustc 1.97.1 a crate handed by path gives the plain "can't find crate for `x`" (no "which … depends on") from `intern_stable_crate_id` (`creader.rs:221`, `CrateError::NotFound`): an earlier, silent load of `x` during import resolution reserved its crate number and then failed on one of the crates `x` depends on; the reporting lookup that follows meets the reserved number. Reproduced locally with four tiny crates (z, q on z, mail on q, z rebuilt under the same name, a dependent handed mail's untouched `.rmeta`): with `use mail::m;` the compiler says exactly `E0463 can't find crate for `mail``; with `mail` used only in an expression it says E0460 "found possibly newer version of crate `z` which `mail` depends on". So the plain E0463s (13:11Z `tilolang_tilo`, 15:00Z `mail`, three on 11-13) and the E0460 of 11-13 are one fault: **in the job's deps directory a crate below the named one is of another build than its dependents were compiled against.** The named file being whole and unchanged is consistent with that. Both of today's came minutes after a promote, in jobs that started before it and ran across the worker's upgrade. The earlier five did not. Next, in my file (`wrapper/run.rs`): on this refusal run the failing command once more with `RUSTC_LOG=rustc_metadata=info`, bounded, and put the loader's `Rejecting via hash` line (crate, file, expected and found hash) into the message, so the next one names the crate that is of another build. A diagnostic, to go once the cause is fixed. The open question stays how the other build gets there; the joined compile's early metadata followed by another compile's outputs, after a restart ended the holder's claim, is the candidate I would read first. ## 2026-11-14 15:39Z: the second ask is on main b77a95ed and b1b11710 (`crates/t-cache/src/cargo/wrapper/run.rs` only; whole check set on testing green, run r3e0935d7fa). On the plain E0463 of a handed crate whose file is there and not empty, the wrapper runs the same compile once more with `RUSTC_LOG=rustc_metadata=info` (one attempt, at most 20 s and 16 MiB of stderr, then killed and reaped) and the refusal ends with what the loader rejected, for example: > …error[E0463]: can't find crate for `mail`; asked again with its loader's log on, the compiler rejected: crate `z` (which `q` depends on) in out/libz-zz.rmeta and out/libz-zz.rlib via hash: expected 0cf2c16c… got 8012ab15… or "the compiler took the crate" (a state of the moment), "named no rejection", or "could not ask the compiler again". Every other refusal is told as before, and no passing or ordinarily failing compile runs anything more. Not on production yet; the upgrade proof with running jobs is running on testing. It is a diagnostic: it goes once the cause is fixed. **15:57Z:** b1b11710 is green on the forge and on testing (r3de76448cc), and a worker upgraded from 4d2ee46f to it on testing at 15:53:44Z re-attached its 14 running jobs; the run they belonged to (r1ce87b9095) ended 8 of 8 with 39 jobs passed and none lost. It can ride with the next promote. ## 2026-11-14 17:00Z: a third one, 8 minutes after the 16:46Z promote; three restarts of four today | restart (Z) | refusal (Z) | job | started | refused crate | how its file came to be | |---|---|---|---|---|---| | 13:02:57 | 13:11:41 | j569-84627, a person's `test-x86_64` | 12:56:51 | `tilolang_tilo` (.rlib) | compiled by the job 13:02:25, 32 s before the restart | | 14:58:03 | 15:00:45 | j570-54944, a head's `test` | 14:47:01 | `mail` (.rmeta) | placed from the cache 15:00:07, 104 s after it | | 15:26:46 | none in 80 minutes | | | | | | 16:46:25 | 16:54:27 | j572-93547, a person's `test` | 16:42:51 | `backups` (.rlib) | compiled by the job 16:45:12, 73 s before the restart | Every one is in a job that started before a promote and ran across the worker's upgrade; every refused file is whole and unchanged. The 16:54Z line (old wrapper, so no second ask yet): > compiling crate `contents`, the compiler couldn't find crate `backups` cargo handed it (/target/debug/deps/libbackups-cd1711064b51ef0f.rlib, 18629228 bytes as the compile started, 18629228 bytes now; the same file, unchanged since the compile started (inode 20401105103, modified 2026-11-14T16:45:12.375011041Z, changed 2026-11-14T16:45:12.375011041Z); content blake3 205ae23e…fc75; an archive whose first member is the symbol table): error[E0463]: can't find crate for `backups` By what the plain E0463 means (above), a crate below the refused one was another build when the dependent compiled, minutes after the restart, than when the refused crate compiled, just before it. So **something replaces a crate file in a running job's deps directory across a restart.** What the worker's log shows for j572-93547 after the restart (worker re-attached 16:46:44.97Z, 60 jobs): two compiles started at 16:46:46 and 16:46:51, one of 66 s and one of 459 s (5.5 GB peak, 678 CPU seconds); when the long one ended at 16:54:25 nineteen compiles of 0.1 to 0.3 s followed within two seconds, the refused one among them. The 15:00Z job has the same mark: its two long compiles started 19 s after that restart's re-attach. Across all jobs 352 compile slots started in the 40 s after the 16:46Z re-attach. A lead I have not shown: before the restart the job's compile of that unit was joined to another job's, the holder's metadata was placed and announced (`take_metadata`), and dependents compiled against it; the restart ended the claim, the wrapper asked again, found no holder (`join`: `Watched::Free`, then `Found::Run`) and compiled the unit itself, writing other metadata over the announced file. What it lacks is why two builds under one key would differ. `slots.again` is not it: it answers nothing for a slot the new daemon does not know. From 16:46Z the wrapper asks the compiler again on such a refusal, so the next one in a job started after that names the crate below, its files and both hashes. **18:42Z, the one comparison I can make:** I hold the worker's log across two restarts. Compile slots that started within 40 s of the worker's re-attach: at 16:46Z (a refusal followed) 728 in 11 jobs, four of them 120 s or longer, in two jobs: the refused job's 459 s compile and three in j572-92948 (201, 175 and 127 s; that job: j572-92948 | test | ci | pass | - | 16:39:46 | 16:57:35); at 17:09Z (no refusal followed) 158 in 12 jobs and none of 120 s or longer. Also checked and empty: the read sets stored with the refused `mail` and `backups` entries name sources only (96 and 18 `.rs` files, no crate file of the deps directory), so crates below enter a key only through the bytes of the directly handed files; and neither `entries` nor `entries_log` holds two builds of one key to compare (one put a key, and no key under both trusts for these crates in twelve hours). ## 2026-11-15 23:14Z: one more, 17.5 hours after the last restart, and the second ask names no hash Since the table above: | restart (Z) | refusal (Z) | job | started | refused crate | how its file came to be | |---|---|---|---|---|---| | 19:12:11 11-14 | none | | | | | | 20:49 11-14 | none | | | | | | 00:06 11-15 | none | | | | | | 05:45:08 11-15 | 23:13:55, 17 h 29 min later | j578-25355, a person's `cargo build -p agent --release` | 22:51:51 | `tilo_agent` (.rlib) | compiled by the job itself, written 22:57:13, 16.5 minutes before | So four restarts in a row brought none, and this one came with no restart near it: production 1b22804f, the node fully busy (people's jobs on 136 of 154 cores in that minute), no squeeze on the disk (1,230 GiB free). The ending, from the server's log (saved, with the worker's log of the job): ``` compiling crate `tilo_agent`, the compiler couldn't find crate `tilo_agent` cargo handed it (/target/release/deps/libtilo_agent-98cea62d9d77b279.rlib, 19221270 bytes as the compile started, 19221270 bytes now; the same file, unchanged since the compile started (inode 14764083701, modified 22:57:13.007Z, changed 22:57:13.240Z); content blake3 dbf4de56…; an archive whose first member is the symbol table): error[E0463]: can't find crate for `tilo_agent`; asked again with its loader's log on, the compiler rejected: crate `serde_derive` (which `serde` depends on) in …/libserde_derive-ebbe3101b41187ff.so via proc macro: expected false got true; … `zeroize_derive` … `der_derive` … `curve25519_dalek_derive` … `zerocopy_derive` … `hax_lib_macros` … via proc macro: expected false got true ``` What it shows and what it does not: - All six rejections are the locator's ordinary first look at a proc-macro dependency: it starts with `is_proc_macro = false`, turns the `.so` away, then loads it as a proc macro. a24aac0c leaves out the other direction ("expected true got false") only. So the second ask names **no rejection by hash**: no other build of a crate below was turned away when the compiler was asked again a moment later. That is new against the three of 11-14, which the message could not yet read. - The job (worker's log, 481 lines): 477 compile slots, every one `found=false`, a release build with nothing in the cache, so every file in its `/target` was written by this job. The library's own compile ended 22:57:13.19Z (30 s). A 591 s compile with a peak of 9.6 GB ended 23:13:52.34Z after waiting 444 s for its slot. The failing unit, the package's bin with the same crate name, ran 0.83 s and ended 23:13:54.68Z. - So this is neither a placement from the cache, nor a restart, nor a file that changed: one job, its own files, sixteen minutes old, and the compiler did not find a crate at the first ask. Open, and how I go on: the check's log (t ran the erred check again; a step of mine saves the log when that run ends) should say whether the second ask loaded the crate, which would make the first failure a passing one in the job's own directory, not a wrong file. And the message needs one more cut, mine to make: leave out "expected false got true" as well, and say "named no rejection" when nothing is left. **23:35Z, the same check run again.** t ran the erred check once more in the same run (raf5099ab0c): job j578-26180 passed, `Finished release profile … in 19m 53s`, 961 of its 1,915 compiles from the cache (the 953 the refused job had stored among them) and 953 stored. So the inputs and the cache's entries were sound, and the failure belonged to the first job's own directory at that moment, as on 11-14 at 13:11Z and 16:54Z. **02:05:54Z 11-16: once more, 55 minutes after a restart, in a job that ran alone in its files.** Production 8bd4b1f2 (server and worker pod both new since 01:10Z and 01:14Z). | | | |---|---| | job | j580-7815, `test/tilo-session-client`, people's (run re2221ab15e, quinten), width 6, launched 02:00:27Z | | refused | compiling `tilo_session_client`: `can't find crate for tilo_session_core`, plain E0463 | | the file | `/target/debug/deps/libtilo_session_core-4ff9ae93bdf04e61.rlib`, 11,049,382 bytes, same inode, modified and changed 02:00:37.7Z, unchanged since the compile started | | asked again | six lines, all `via proc macro: expected false got true`: no rejection by hash, as at 23:13Z | | cause given | `cache_unreachable`; t asked the check again (j580-8070), the asker stopped the run a minute later | What the worker's log adds (saved, `refused-0205-worker.log`): the job ran eight compiles of its own, all `found=false`. Seven were short. One took 246.6 s with four tokens and a peak of 6.3 GB, after waiting 65 s for its slot, and ended 02:05:48.45Z. The two compiles that failed started about 02:05:51Z and ended 02:05:54.2Z after 3.2 s each. So the picture is the same as at 23:13Z on 11-15 (a 591 s compile with a 9.6 GB peak ended 3 s before the refusal): **both times the refused compile started within three seconds of the end of a multi-gigabyte, minutes-long compile in the same job, and the crate file it could not find had been lying there unchanged for minutes.** The file was in place before any compile of this job started (02:00:37.7Z is the second its first slot began), so it came with the build directory or a placement, not from the long compile. What I could not read: which crate the long compile was, and what cargo printed. The job's directory was gone six minutes after its end, the stopped run's check answers `cancelled` with no log, and the slot lines' `unit` is not `sha256(ident)` of `t.entries`. From now a step of mine (`refusal-capture.sh`) follows the server's log and copies the job's `out.stderr`, `compile-reads` and `observed` and both pods' logs in the second the line appears. Six jobs ended `cache_unreachable` in 48 hours: four on 11-14 (08:11Z, 13:11Z, 15:00Z, 16:54Z), 23:13Z on 11-15 and this one. **03:00Z 11-16: what the code says about the seconds after a compile (read on main 8d2d89b1), and one thing both cases share.** Both saved worker logs hold exactly one line `moving a wrapper out of its slot: write <pid> to …/own/cgroup.procs: No such process`, and both times it is the refused job's, in the 10 ms after the refused compile's slot ended (23:13:54.687Z on 11-15, 02:05:54.219Z today). Read in the code it is a result, not a cause: a wrapper that refuses leaves without `Done` (`slot.rs:111-113`, `compile.rs:81`, `entry.rs:152`), and `release()` then writes a pid that is gone (`slots.rs:1598-1605`). The check that should skip that error never matches, because `write_existing` wraps it through `named()` and the wrapped error carries no OS error number (`cgroup.rs:229-235, 1557-1560`). Small, mine to fix with the message's cut. What touches a job's target directory, by the code: - After a successful compile: nothing writes there on Linux. `store()` reads and stats the outputs, the node's `put` copies or clones them into its store and leaves the job's files alone (`put.rs:103-212`, `cas/put.rs:363-415`), and nothing works on them after the wrapper has returned to cargo. - A placement on a hit is a copy made under `/target/.t-placing` and renamed over the destination (`cas/place.rs:213-219`): old file or new, never none. Only the asking unit's own outputs are placed. - No memory limit is lowered when a slot ends (`cgroup.rs:791-818`), and a slot's end kills nothing (`cgroup.rs:1142`). - The one window found: a placement that fails part way unlinks what it had already renamed into place (`daemon/place.rs:102-105, 367-373`). If that unit's `.rmeta` had been announced before (`lookup.rs:254-274`), dependents cargo started on it can lose the file. It concerns the failing unit's own outputs only, and I cannot tie it to either job. So the long compile's end is not, by the code, a moment when files move. What stays unexplained is why a compile fails at the first ask and names no rejection at the second, three seconds after such a compile, twice. The next capture (`refusal-capture.sh`, armed since 02:16Z) should give cargo's output and the job's compile reads, which say which crate the long compile was and whether its metadata had come from another job's claim while this job waited 65 s in that claim's line before compiling it itself. **03:05Z 11-16: what the long compile before each refusal has in common: it had waited on another job's claim, then compiled the unit itself.** The slot line's `waited_ms` counts the time a compile stood on another job's claim (`conn.waited`, `node/daemon/lookup.rs` `join`), `queued_ms` the time for its slot. In the two saved worker logs, 6,142 slot lines, three compiles ran themselves (`found=false`) after standing 5 s or more on a claim: | ended (UTC) | job | check | compile | stood on a claim | then | |---|---|---|---|---|---| | 11-15 23:13:52 | j578-25355 | `cargo build -p agent --release`, people | 591 s, 9.6 GB | 444 s | refused 3 s later (a dependent, 0.8 s) | | 11-16 01:37:33 | j580-1465 | `test`, CI | 449 s | 352 s | nothing: the job passed | | 11-16 02:05:48 | j580-7815 | `test/tilo-session-client`, people | 247 s, 6.3 GB | 65 s | refused 3 s later (two dependents, 3.2 s each) | So both refusals follow such a compile, and two of the three such compiles are followed by a refusal. In today's case the holder was j580-7471 (the same unit, 275 s, ended 02:02:26Z); the waiter left its line at 02:01:42Z, 44 s before the holder ended, and compiled the unit itself. What the code rules out: a waiter does not take a holder's metadata on the first key alone. `Claims::watched` hands a holder's step only to a watch whose own keys hold the step's `key1` (`jobs/claims.rs`, `if keys.contains(&step.key1())`), and tells the others the holder's read set instead. So a waiter whose files differ is told the read set, finds its key differs and compiles itself, which is what the 65 s and the 444 s look like. What is open: why the unit's dependents then fail at the first ask. The dependents that were already in the job's directory (today `tilo_session_core`, in place since the job's first second) were not rewritten after the waiter's own compile, so either they do not depend on that unit or their re-ask was a hit on the same bytes (a placement leaves a file with the same hash alone, `daemon/place.rs:293-305`). The capture step should show, from the job's compile reads, which unit the long compile was and what each dependent was keyed on. ## 08:25Z 11-16: the two cuts are on main (0dd1b888, 95b08710), not on production yet - **The message** (`crates/t-cache/src/cargo/wrapper/run.rs`, `rejected`): `Rejecting via proc macro: expected false got true` is left out as the other proc-macro line is. Both refusals with the diagnostic on (23:13:55Z on 11-15, 02:05:54Z today) listed six of them and nothing else; from the build that carries this such a refusal ends "the compiler named no rejection", or "took the crate". - **The warning** (`src/node/cgroup.rs`, `src/node/slots.rs`): `cgroup::move_process` moves a process into a cgroup and answers a process gone meanwhile (`ESRCH`) apart from an error; `Slots::release` and the node's start use it. `write_existing` names its error through `named`, which keeps no error number, so the skip in `release` never matched and each refusal was followed by "moving a wrapper out of its slot: … No such process". That line was a result of the refusal, never a cause. - Whole check set on testing green (run rc55109322a), forge workflow green, testing's image built. They ride the next promote; I do not promote them alone. The cause of the refusals themselves is as open as above: no refusal since 02:05:54Z, and the capture step is still armed. ## 16:45Z 11-17: a fourth refusal, and what the times and the cache's rows show Job j603-10955 (a person's `test-x86_64/tilo-agent-session`, run r8ebab3caf5, production f5147065, two hours after its start, 1,283 GB of disk free: no squeeze) ended `error | cache_unreachable` at 16:45:17Z: compiling crate `it`, E0463 for `tilo_agent`; asked again, the loader rejected `tilo_ui` for three dependents (`tilo_app`, `tilo_desktop_surface`, `tilo_feedback_transport`) "via hash: expected 8471a484… got 55bb4d27…" in `libtilo_ui-f4f1add1974eae79.rmeta` and `.rlib`. In order (the worker's slot lines, `t.entries`, `t.job_history`): | time (Z) | what | |---|---| | 16:30:57 | run r58be5b61e2 asked; its job j603-10885 | | 16:31:39 | run r8ebab3caf5 asked by the same session, same check; its job j603-10955 | | 16:35:25 | j603-10885 starts compiling tilo_ui (the worker's unit 3c12182b) | | 16:37:31 | j603-10955 asks for tilo_ui and stands on j603-10885's claim (slot line `waited_ms=99948 queued_ms=5`) | | 16:37:41 | j603-10955's cargo starts tilo_app, a dependent of tilo_ui, though its own compile of tilo_ui has not begun: tilo_ui's metadata is in its directory. tilo_app stands 25.6 s on j603-10885's claim | | 16:38:07 | j603-10885 stores tilo_app (`libtilo_app-1195715b7692414d`, key0 7f4e66a94cc3494c, key1 1c2d0610…); j603-10955, of the same key0 and another key1, compiles tilo_app itself | | 16:39:09 | j603-10955 stores its tilo_app (key0 7f4e66a94cc3494c, key1 7c7722e1…, 62.2 s) | | 16:39:11.49 | j603-10885 is cancelled (its run was stopped) 225.9 s into tilo_ui; it stores no tilo_ui | | 16:39:11.5 | j603-10955 is told to run tilo_ui itself (351.5 s); four more of its compiles start in the next 47 s | | 16:45:03 | its own tilo_ui ends; stored 16:45:04 (key0 3e7d4022…, key1 3b211a51…) | | 16:45:07 | `it` starts compiling; refused at 16:45:16 | **Reading.** Both tilo_app entries have one key0, so both were compiled against the same tilo_ui metadata: the holder's, which the claim handed to the job in line (`Reply::Metadata`: the node places it, `src/node/daemon/lookup.rs:286-304`; the wrapper announces it to cargo, `crates/t-cache/src/cargo/wrapper/conn.rs:111-114`). The holder never finished. Told `Run` (`find.rs:365`), the job compiled tilo_ui itself and its compiler wrote other metadata over the one its dependents were built on (55bb4d27 where they expect 8471a484). What E0463 names (`tilo_agent`) is not the crate at fault. **Not explained.** Why the job's own compile gives another hash than the holder's. A metadata step goes only to a waiter whose keys hold the step's key1, so by the keys both compiled the same inputs: either the compile is not reproducible, or the two differ in something the key does not hold. What the cache shows: in 24 h it kept one key1 of tilo-ui and two of tilo-app under two trusts (two compiles of identical keyed inputs), and all three pairs have identical output files. The two runs do differ somewhere: tilo_app's key1 differs between them. **The old signature is not enough.** On 11-17 (00:00 to 16:55Z) 801 of 801,058 slot lines are compiles that stood 5 s or more on another job's claim and then ran themselves; one job was refused. It takes all three: metadata taken from the holder, the holder gone before its library, and other metadata from the job's own compile. **Next (one log line, no change on the wire, nothing a job does changes).** Where the node places a holder's metadata for a job in line (`Inner::take_metadata`, `src/node/daemon/lookup.rs`) it now says so, with the waiting job, the holder's node, the file's name and content hash, the waiter's key0 and the step's key1: landed on main as 9d09529f at 17:14:13Z (whole check set on testing green, run rab329f8271: 8 passed, 0 failed, 0 errors). It is live on production since the 18:30:03Z promote of 2885a521: sixteen such lines in the first ninety seconds after the worker re-attached, so a holder's metadata is handed to jobs in line all the time and nearly always ends well. At the next case the line gives the holder's metadata hash and key1; `t.entries` gives the key1 and the metadata hash the waiter's own compile stored. The same key1 with another hash is a compile that is not reproducible; another key1 is a step handed under a key that does not describe the waiter's compile. I propose no fix before that. To weigh then: end such a job at the long compile's end under this as its named cause (it cannot pass, and today it runs on to a misleading E0463), or let a cancelled holder finish a compile others took metadata from. t ran the check again in the same run (j603-12636). The capture step copied nothing: the job's directory was gone within seconds of its end. **18:46Z 11-17: c0f2a058 on main (yours) takes the first of the two ways I listed, and carries the diagnostic with it.** The node keeps what a job announced from another job's claim and ends the job at the compile that writes other metadata over it, as `metadata_replaced`, with both hashes and both key1s, and the check is asked again. Once it is on production the next case says by itself which of the two causes it is: the same key1 with another hash is a compile that is not reproducible, another key1 is a step handed under a key that does not describe the waiter's compile. What stays open here is only that: why two compiles of one key differ. I will add the first `metadata_replaced` end to this issue and close it if the answer is in the keys. ## 01:25Z 11-18: the next case came across a worker's upgrade, and was told `cache_unreachable`, not `metadata_replaced` **The job.** j605-532, `test-x86_64/tilo-agent-session` of probe run r34481520a9: started 01:15:33Z on 7710cc0d (which has c0f2a058), ended 01:25:58Z on ab189001 as `error | cache_unreachable`. It is the one job of t's own that erred across your 01:21:32Z promote (my check ten minutes after: 54 other jobs that ran across it ended on their own). **What it was handed** (my line from 9d09529f, "a holder's metadata is placed for a job in line", all with holder node t-worker-ci-x86-1): | time | file | key0 | key1 | |---|---|---|---| | 01:19:27.80Z | libtilo_ui-7f994c480d8722bf.rmeta | 8c3fd7c1dc41… | c8c8e69… | | 01:21:16.61Z | libtilo_ui-d31143600bc07638.rmeta (hash a9121f3ceb49…) | dd579c0e994a… | 0322064… | | 01:21:16.63Z to 01:21:17.39Z | tilo_runner_native, tilo_emoji_catalogue, tilo_feedback_transport | | | **Then the upgrade.** Server start 01:21:32Z; the worker "fetched the server's build" at 01:21:42.67Z and "re-attached to the jobs on disk jobs=58" at 01:21:51.39Z. From 01:21:57Z the job's slot lines carry the new daemon's slot ids, and about 35 of its compiles end within nine seconds. At 01:25:58Z rustc: compiling `it`, can't find crate `tilo_agent`; with its loader's log on: "crate `tilo_ui` (which `tilo_app` depends on) in libtilo_ui-d31143600bc07638.rmeta and .rlib via hash: expected 0e1b1289… got a942919e…", and five more candidates of tilo_ui. The same signature as 16:45Z: the file it had been handed 16 seconds before the restart held other metadata at the end. **Why c0f2a058 did not name it.** What a job announced is kept in the daemon's memory alone: `Inner::announced` (`src/node/daemon/inner.rs:96`) begins empty in each daemon (`handle.rs:83`), and nothing in `src/node/attach.rs` fills it for the jobs a worker re-attaches. `Inner::replaced` (`put.rs:115`) then finds no entry for the job and says nothing. What a compile replaced is kept with the job (`run-t/metadata-replaced`, `src/cargo/job.rs`: "kept in the job's directory, not in the daemon's memory"); what it announced is not. So across an in-place upgrade the check of the invariant is blind for every job that announced before it, and an upgrade is when holders go: the new daemon knows no claim the old one held, a job in line asks again, is told to run and compiles the unit itself while the holder's compile goes on too. **What I propose, and will commission unless you take it or object** (one developer of mine builds locally at a time; the next slot is this): what a job announces is written with the job as it is announced, beside `run-t/metadata-replaced`, and read back for the jobs a worker re-attaches, so `replaced` sees it in the new daemon; a test that re-attaches a job across a daemon's restart and then has its compile write other metadata, red on main. It changes a job's files on the node, so it gets the upgrade proof before any promote of mine. It does not touch the other question, which stays open: why the job's own compile of a unit gives other metadata than the holder's. **02:08Z 11-18: that fix is on main, da23690a (not on production).** Each announcement is appended, as it is made, to `metadata-announced` at the top of the job's directory (`<data>/jobs/<job>/metadata-announced`, beside `compile-reads`), one JSON record a line (`cargo::job::Announcement`: path, hash, key1, unit, holder), written by the worker's cache daemon in `Inner::announce_metadata`. It is not under `run-t`, which is bound into the job: the job neither sees nor can write it. A daemon that holds nothing of a job reads the file in `Daemon::serve_job` before it binds the job's socket (`Inner::read_announced`), so no compile of a re-attached job reaches the new daemon before it holds what the old one announced. A file or a line that does not read is one error line and the rest counts; a job from before this build has no file and is served as before. No wire type, nothing a job is told, nothing in the server. Five tests; the one that announces, restarts the daemon and then has the compile write other metadata is red without the read-back ("the compile is refused: Ok"). The job directories' fixture gains the file (format b8a1ec5908b86ed4). t's whole check set green on testing for it on 84cb9365. It adds a file to a job's directory, so I run the upgrade proof for da23690a on testing before I promote (jobs running there across the deploy must all re-attach). Then one promote of main's head for this and #93's change together, on the conditions written in #93. **02:19Z 11-18: the upgrade proof holds for da23690a (testing).** A whole check set forced with a nonce ran at 84cb9365; with 18 job directories on the node, all with a course, da23690a was deployed: the worker "fetched the server's build" at 02:19:50Z and "re-attached to the jobs on disk jobs=14" at 02:19:51Z, none reaped as unattachable, no "missing field", no ERROR line, no panic; the run across it passed its 8 checks (32 jobs, all pass). Forge run on da23690a pending; then the promote, behind the gates written in #93.
Owner

01:25Z 11-18 (j605-532): why the job's own tilo_ui differed from the holder's

tilo_app was built against the holder's metadata. The holder's libtilo_ui-d31143600bc07638.rmeta (blob a9121f3c…, key1 03220645…) was placed for the job at 01:21:16Z and stored by the holder at 01:24:11Z. Its crate root holds SVH 0e1b1289…, exactly what tilo_app expected. At the refusal the file held SVH a942919e…. No cache entry has those bytes: the holder's is the only entry under that file name. So the job's own compile wrote them (unit 3c12182b, ended 01:25:36Z, after the 01:21Z restart and re-attach).

Two compiles of one key gave two crates because rustc folds RUSTC_BOOTSTRAP into the crate hash. With rustc 1.97.1, the same library and arguments give one SVH with it set and another without; -Zthreads at 1, 4, 8 or 14 changes nothing. The wrapper set RUSTC_BOOTSTRAP only for a slot given threads (the head of the critical path) and for links. Keys don't hold the slot.

Since 2026-11-17 01:46Z the cache holds two passing compiles with differing metadata bytes for 316 keys. Nine of those keys have two SVHs: jiff (twice), jiff-tzdb, tempfile, fs4, memfd, gethostname, trash and rustix-linux-procfs. The rest differ only in a table's byte order. Which of the two tilo_ui compiles had threads can't be read any more: slot lines don't log threads, and the holder's line has rotated.

Fix, landing next: every unit's compile runs with RUSTC_BOOTSTRAP=1 whatever its slot, here, uncached and on a peer, as links already did. The slot only adds -Zthreads. Build-script probes are unchanged. A test compiles one unit in a slot with threads and once without, using a compiler whose metadata holds the variable. It is red on main and green with the fix.

da23690a0 stays the check for what is left, such as a holder on an older wrapper during an upgrade. One point on it, Xaver: a record that can't be written or read leaves the job unchecked, so the check fails open. I'd rather it fail the job, or not announce the metadata, in that case. A silent pass is the same as having no check.

**01:25Z 11-18 (j605-532): why the job's own tilo_ui differed from the holder's** `tilo_app` was built against the holder's metadata. The holder's `libtilo_ui-d31143600bc07638.rmeta` (blob a9121f3c…, key1 03220645…) was placed for the job at 01:21:16Z and stored by the holder at 01:24:11Z. Its crate root holds SVH 0e1b1289…, exactly what `tilo_app` expected. At the refusal the file held SVH a942919e…. No cache entry has those bytes: the holder's is the only entry under that file name. So the job's own compile wrote them (unit 3c12182b, ended 01:25:36Z, after the 01:21Z restart and re-attach). Two compiles of one key gave two crates because rustc folds `RUSTC_BOOTSTRAP` into the crate hash. With rustc 1.97.1, the same library and arguments give one SVH with it set and another without; `-Zthreads` at 1, 4, 8 or 14 changes nothing. The wrapper set `RUSTC_BOOTSTRAP` only for a slot given threads (the head of the critical path) and for links. Keys don't hold the slot. Since 2026-11-17 01:46Z the cache holds two passing compiles with differing metadata bytes for 316 keys. Nine of those keys have two SVHs: jiff (twice), jiff-tzdb, tempfile, fs4, memfd, gethostname, trash and rustix-linux-procfs. The rest differ only in a table's byte order. Which of the two tilo_ui compiles had threads can't be read any more: slot lines don't log threads, and the holder's line has rotated. Fix, landing next: every unit's compile runs with `RUSTC_BOOTSTRAP=1` whatever its slot, here, uncached and on a peer, as links already did. The slot only adds `-Zthreads`. Build-script probes are unchanged. A test compiles one unit in a slot with threads and once without, using a compiler whose metadata holds the variable. It is red on main and green with the fix. da23690a0 stays the check for what is left, such as a holder on an older wrapper during an upgrade. One point on it, Xaver: a record that can't be written or read leaves the job unchecked, so the check fails open. I'd rather it fail the job, or not announce the metadata, in that case. A silent pass is the same as having no check.
Sign in to join this conversation.
No labels
No milestone
No project
No assignees
2 participants
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#63
No description provided.