Hi,
We’re on UE 5.8.3, running incremental cooks (-CookIncremental, ZenStore) with multi-process cooking on our build farm, for Windows, PS5 and Linux Server.
The problem
When we change a Blueprint class that’s placed in a World Partition map, the incremental cook doesn’t recook the map’s streaming cells. The cooker reuses the cells from the previous cook, so anything the Blueprint generates at cook time stays stale. In our case that’s components added by its construction script. The cells stay stale on each build agent until something changes the map itself, usually a resave.
Normally this would go unnoticed. We only caught it because the stale cell also carried errors from its original cook.
What happened
We had a Blueprint whose construction script adds SplineMeshComponents and reaches into linked actors in other cells. During cook, that produced errors like:
LogActorComponent: Error: RegisterComponentWithWorld: (...NODE_AddSplineMeshComponent-9_13) Trying to register component in invalid or cleaned up world. Aborting.
We then fixed the Blueprint, with no change to the map or its actor packages:
- Horde build agents whose stored map key no longer matched recooked the cells, and their cooks were clean.
- One agent had last cooked the map right before the fix. It found the map unchanged, reused the old cell, and replayed its errors as
[IncrementalReplay]. So the cook kept failing for a problem that had already been fixed.
Resaving the map with no content change cleared it. The next cook recooked every cell and the errors were gone.
What we think is happening
Reading the 5.8.3 source, two things combine:
UWorldPartitionRuntimeLevelStreamingCelldeclares its dependencies asFCookDependency::Packageon its actor packages,ActorContainerPackageDependenciesand the world package.Packageonly considers the bytes of each file. Nothing points at the actors’ classes, so a Blueprint change doesn’t touch any of them.- In
FRequestCluster, if a generator (the map) is incrementally unmodified, all its generated packages (the cells) are marked unmodified without checking their own keys. The code comment says this is by contract.
So nothing in the chain notices the Blueprint changed. A map resave works around it, because every cell depends on the world package.
Possibly related CLs
Looking through recent incremental cook changes in main, these look relevant:
- 57221715 (from 57221678): adds transitive dependencies from a generator to its generated packages, so a cell that needs recooking forces the map to recook too. The description covers false skips caused by a dependency on a cell (a MIC’s Material) not reaching the map, which looks like the same underlying problem. As far as we can tell it isn’t in our tree.
- 61261605: fixes artifact collection for generator and generated packages that have a build dependency on a missing package. It seems like it should go together with the CL above.
Questions
- Is this a known issue, and is CL 57221715 the intended fix?
- With that change, will a Blueprint-only edit actually make the cell recook? That seems to depend on the cooked cell recording a dependency on the classes of the actors it contains. Does that happen automatically for generated packages, or should the cell declare those class packages itself?
- Can 57221715 be cherry-picked to 5.8.3 with just 61261605, or are there other prerequisites?
- Is it intended that a reused package replays its old errors and fails the cook? It helped us spot the stale cell, but the only way to clear it was to change the map.
Happy to share more info if that would help.
Thanks!