We're using version 0.5.1
from stockholm import Currency
c1 = Currency("RWF")
c1
# <stockholm.Currency: "RWF">
c1.decimal_digits
# 2
c2 = Currency.RWF
c2
# <stockholm.Currency: "RWF">
c2.decimal_digits
# 0
This causes a bug for us where 100x as much money was passed as intended
from stockholm import Money
t = Money("1673861354.00", "RWF")
t
# <stockholm.Money: "1673861354.00 RWF">
t.sub_units
# Decimal('167386135400')
int(t.sub_units)
# 167386135400
Workaround:
c3 = getattr(Currency, "RWF")
c3
# <stockholm.Currency: "RWF">
c3.decimal_digits
# 0
We're using version 0.5.1
This causes a bug for us where 100x as much money was passed as intended
Workaround: