I've never been able to figure this one out, it appears to be related to the EEI's existence (since the moment charging finishes it becomes possible to enter or exit a stopped locomotive). Travelling in a wagon isn't an issue, nor exiting locomotives once they're fully charged. I will ask the experts over on the Discord for help, hopefully they'll have something.