Error while using HLODS | Assertion failed: Index.IsExport() && ExportMap.IsValidIndex(Index.ToExport()) [File:D:\build\++UE5\Sync\Engine\Source\Runtime\CoreUObject\Public\UObject\Linker.h] [Line: 165]

If you are getting this error while using HLODs + World Partition, you probably have an actor with an incorrect HLOD layer and “spatially loaded” assignment.
In my case, it was foliage. The instanced foliage actor had the “Is spatially loaded” option enabled but no HLOD layer assigned.