The reason could be that discharge balance was lost at the last period of discharge. OR when fresh and used batteries are mixed in the same appliance. As a consequence, the polarity reversal phenomenon occurred.
Polarity reversal may happen when more than two batteries are connected in series and used until the last moment of discharge.
When a large capacity of electric current beyond the limit leaves the battery, a minor difference in battery capacity could result in a serious decrease in electric balance - reversing the batteries’ polarity.