Running Stellarmate / KStars 3.6.8 and PHD 2.6.1 on a home built Rasp Pi4

I'd appreciate any ideas on an annoying problem.

I set up to image, PA, focusing, tracking, guiding is working fine.
At the appropriate time the meridian flip occurs.
Scope is re-aligned correctly onto the target.
Tracking and guiding start (PHD2 is recalibrating after every meridian flip(?)
Refocusing starts which pauses guiding
Then before focus finishes, guiding is aborted which stops the imaging sequence.
I can manually get everything reset and off it goes again until the end of the night but it means I can't leave it unattended.