These algorithms are rather dumb -- they sort the threads according to the date of the thread root (!). This means that a new reply to an older thread won't bring the thread forward. Issuing a SORT can be rather expensive, but a good heuristic might be to at least sort in the implicit mailbox order by UIDs -- no network traffic is required for that. https://projects.flaska.net/issues/568
Thank you for the bug report. As this report hasn't seen any changes in 5 years or more, we ask if you can please confirm that the issue still persists. If this bug is no longer persisting or relevant please change the status to resolved.
Trojitá is no longer maintained, please switch to a maintained alternative like https://apps.kde.org/kmail2/ Sorry for the inconveniences.