Remove unnecessary prehash suffix ``...`` when count unmerged commits
Support python3
Merge in upstream changes.