What is the problem?
Elected candidates should never be considered for elimination.
In an edge case, it may be possible for an elected candidate's vote count to be considered the "lowest" in the ranking because the transfer of surplus to a hopeful candidate increases their vote count. This would cause the elected candidate to be declared eliminated.
(Quoted from https://gerrit.wikimedia.org/r/c/mediawiki/extensions/SecurePoll/+/715196)
This bug was found by @STran.