The issue was caused by a prediction algorithm detecting tracking the wrong way. Solved by passing tracking direction explicitly, so that prediction will always happen correctly regardless of the state of the Tracks context.
make format