# A rendered editor commandlet on a cold checkout hits its timeout during Vulkan SM6 shader compilation (`rc=124`)

- **Status:** current
- **Engine:** ue6-main `61e2877e`, Linux x86_64, Epic clang 23.1.5 (v27 SDK).
- **Context:** Standalone UE6 editor commandlet with `-AllowCommandletRendering -RenderOffscreen`, started in a fresh clone whose project-local `DerivedDataCache` is empty. The commandlet runs through the build wrapper under a bounded `timeout`, on a shared build machine.
- **Prerequisites:** A compiled project editor module, the offscreen commandlet flags, a project-local filesystem DDC (`-ddc=(ProjectPak,EnginePak,Local)`), and the bounded timeout around the command.

## Symptom

On a cold checkout the first commandlet that initializes the offscreen Vulkan SM6 renderer compiles shaders before the script runs. With a 900-second limit the wrapper returned `rc=124`. The engine log shows the Python script starting 14 min 55 s after the engine's first log line and the first glTF import beginning one second later. The log ends about a second after that, when the timeout does. No `STYLOO_IMPORT` line was written, so the import did not finish.

```text
LogShaderCompilers: Display: Using 8 local workers for shader compilation
LogShaderCompilers: Display: Job FTSRRejectShadingCS(permutation 226, format SF_VULKAN_SM6_LINUX) compile time exceeded threshold (59.370s)
LogMaterial: Display: Missing cached shadermap for /Engine/EngineMaterials/WorldGridMaterial.WorldGridMaterial in VULKAN_SM6_LINUX, Default, SM6, Editor (DDC key hash: …), compiling.
```

The wrapper's copy of that log has 144 `Missing cached shadermap` lines and 12 `compile time exceeded threshold` lines.

## Smallest example / reproduction

In a fresh clone, run the first asset commandlet offscreen with a 900-second limit. This is the command as the Step 12b script ran it before commit `4132d2c`; the arguments are as the log's command line records them, and `$P` is the clone.

```bash
"$WRAP" step12b-fresh-ue_import timeout -k 15s 900s "$UE/Engine/Binaries/Linux/UnrealEditor-Cmd" "$P/CoopZero.uproject" \
  -run=PythonScript -Script="$P/Scripts/ue_import.py" -unattended -nosplash -nosound -stdout \
  '-ddc=(ProjectPak,EnginePak,Local)' "-LocalDataCachePath=$P/DerivedDataCache" \
  '-ini:Engine:[DevOptions.Shaders]:NumUnusedShaderCompilingThreads=24' \
  "-abslog=$P/Saved/step12b-fresh-ue_import.log" -AllowCommandletRendering -RenderOffscreen
```

## Solution

Give cold offscreen commandlets a bounded timeout that covers the shader compile. Coop Zero commit `4132d2c` changes one line of `Scripts/build_slice.sh`, `timeout -k 15s 900s` to `timeout -k 15s 1800s`, with the comment that cold Vulkan shader compilation can take over 15 minutes at the wrapper's priority. Keep the limit bounded.

When a commandlet ends with `rc=124`, read the last phase in its log before treating it as an asset or Verse error. If the log's last lines are `Missing cached shadermap … compiling` and the script's own result line is missing, it is the cold start.

## Why it works

The timeout ends the process from outside the editor. A cold offscreen editor start on this host spent 8 to 15 minutes compiling shaders before its script ran, so a 900-second limit could end the process inside that phase or just after the script began. With 1,800 seconds the two later cold starts finished. The compiled shaders then sit in the project-local DDC, and the same commandlet on a warm cache took 28 to 33 seconds.

First to last engine log line, counted from the wrapper logs on 25 Nov 2026:

| Run | Time | Result |
|---|---|---|
| Step 01, first cook commandlet, 600 s limit | 12 min 49 s | wrapper `rc=124`; the cook still logged `Cooked packages 595 Packages Remain 0 Total 595` |
| Step 04, offscreen map placement, cold | 11 min 15 s | exit 0 |
| Step 12, fresh clone, first import | 8 min 01 s | completed |
| Step 12b, clone at `cbceb94`, first import, 900 s limit | 14 min 57 s | `rc=124` |
| Step 12b, clone at `4132d2c`, first import, 1,800 s limit | 8 min 29 s | `rc=0` |
| Step 12b, clone at `8fb9c75`, first import, 1,800 s limit | 11 min 03 s | `rc=0` |
| Step 12b, main checkout, warm cache | 28 s and 33 s | `rc=0` |

## Verified

- **Evidence level:** runs in editor. After the change, the pristine clone at `4132d2c` ran all asset stages and logged `SLICE_MAP actors=65 map=/Game/Maps/Slice unmanaged=0`. The same sequence then logged `BUILD SUCCESSFUL` and passed the packaged smoke test, which is runs in packaged build ([slice recipe](/docs/recipes/slice-1-summary/)).
- **How:** Before the change, `Saved/step12b/import-timeout/console.log` shows `Result: Succeeded` for the editor compile, then `rc=124` for the import; the engine log is `Saved/step12b/import-timeout/step12b-fresh-ue_import.log`. After it, `step12b-fresh-ue_import-1125-061058.log` and `step12b-fresh-ue_import-1125-070356.log` are the two cold imports that ran to the end. The console records are `Saved/step12b/build-inputs-console.log` and `Saved/step12b/final-console.log`.
- **Date / by:** 2026-11-25, Coop Zero Step 12b. The earlier instances are from Steps 01 and 04.

## Limits and assumptions

One host, with other builds sharing it; the load is not quantified. Each time is a single observation, and the engine log timestamps are UTC. "Cold" here means an empty project-local DDC in a fresh clone. Whether a shared or pre-warmed shader cache avoids the compile was not tested. No engine setting was changed, and none was tried to shorten the cold start. The engine is not at fault in this record: the limit was the lane's own.
