Closed damiendr closed 4 years ago
Hi @damiendr! Thank you for this, and sorry for taking so long to get back to you. I've merged this now and it should be released soon.
Released in 1.10.0
, which also drops support for Python 3.5 and includes #40
The current implementation of
ratio_split()
distributes any change left after rounding to the last participant.This causes two minor issues:
ratio == 0
may still end up receiving change (debit or credit)This PR fixes this by using the Largest Remainder method to allocate change between participants with a
ratio != 0
.It also fixes a further problem whereby
ratio_split()
assumedDECIMAL_PLACES=2
.