JobTempAlloc has allocations that are more than 4 frames old

My game spams the following messages in the console:

Internal: JobTempAlloc has allocations that are more than 4 frames old - this is not allowed and likely a leak
Internal: JobTempAlloc has allocations that are more than 4 frames old - this is not allowed and likely a leak
Internal: deleting an allocation that is older than its permitted lifetime of 4 frames (age = 6)
Unity.Collections.Array:Resize(Void*, Int64, Int64, AllocatorHandle, Int64, Int32)
Unity.Collections.Array:Resize(T*, Int64, Int64, AllocatorHandle)
Unity.Collections.Unmanaged:Free(T*, AllocatorHandle)
Unity.Entities.EntityCommandBuffer:FreeChain(EntityCommandBufferChain*, PlaybackPolicy, Boolean)
Unity.Entities.EntityCommandBuffer:smile:ispose()
Unity.Entities.EntityCommandBufferSystem:FlushPendingBuffers(Boolean)
Unity.Entities.EntityCommandBufferSystem:OnUpdate()
Unity.Entities.ComponentSystem:Update()
Unity.Entities.ComponentSystemGroup:UpdateAllSystems()
Unity.Entities.ComponentSystemGroup:OnUpdate()
Unity.Entities.ComponentSystem:Update()
Unity.Entities.ComponentSystemGroup:UpdateAllSystems()
Unity.Entities.ComponentSystem:Update()

[C:\buildslave\unity\build\Runtime\Allocator\ThreadsafeLinearAllocator.cpp line 962127208]

Internal: deleting an allocation that is older than its permitted lifetime of 4 frames (age = 5)
Unity.Collections.Array:Resize(Void*, Int64, Int64, AllocatorHandle, Int64, Int32)
Unity.Collections.Array:Resize(T*, Int64, Int64, AllocatorHandle)
Unity.Collections.Unmanaged:Free(T*, AllocatorHandle)
Unity.Entities.EntityCommandBuffer:smile:ispose()
Unity.Entities.EntityCommandBufferSystem:FlushPendingBuffers(Boolean)
Unity.Entities.EntityCommandBufferSystem:OnUpdate()
Unity.Entities.ComponentSystem:Update()
Unity.Entities.ComponentSystemGroup:UpdateAllSystems()
Unity.Entities.ComponentSystemGroup:OnUpdate()
Unity.Entities.ComponentSystem:Update()
Unity.Entities.ComponentSystemGroup:UpdateAllSystems()
Unity.Entities.ComponentSystem:Update()

[C:\buildslave\unity\build\Runtime\Allocator\ThreadsafeLinearAllocator.cpp line 962127288]

This only happens in a build not in the editor.
How can I find out where this allocation happened?

I have the suspicion it might be connected with the usage of an EntityCommandBuffer in the FixedStepSimulationSystemGroup.
That might explain why it only happens in a build as the higher framerate will result in more frames between each FixedStep.

I’ve also been dealing with this, using 2020.3 and Entities 0.51.1-preview.21. Every second or so I get

followed by ~10

What’s really strange is that I can only seem to get this warning when leak detection is turned off and I can’t get a stack trace on the allocation no matter what I try.