You're absolutely right the current method is flawed:
When the short stack wins at least a piece of the main pot, the main and side pots are reported separately.
When short stack loses, the main and side pots are combined into a single pot and ALL three players are considered as going AI on the same street - and therein lies the problem.
Whenever players are AI on different streets, always calculate main pot and side pot(s) separately - don't combine them.
We have a bugticket on this issue is HM-6112. I've added your email address to the bug ticket, so you'll be automatically notified when it is fixed