It’s almost always G28 position not being set, which should be disabled in your postprocessor if you haven’t specifically setup a G28 location - it’s usually a tick box to disable. The alternative is that you should remove/replace the G28 call with a safe movement like G53 Z0 if you have homing enabled or remove it entirely.