cadrumo.core.money package

Canonical Decimal money primitives.

Single authoritative implementation of the half-up euro-cent rounding convention used across every AEAT calculation surface (LIRPF art. 23.1 rental net income, IRPF deductions, IVA prorata, asset depreciation, inventory cost basis). Callers import rounding.round_to_cents() and the CENT quantum from the defining rounding module rather than reimplementing the quantize call. This package initializer is inert.

The half-up rounding mode (ROUND_HALF_UP) matches the AEAT publication convention: a residual cent of exactly 0.5 rounds away from zero. Python’s default banker’s rounding (ROUND_HALF_EVEN) does NOT match AEAT and must never be used at the euro-cent boundary for any operator-facing or filed value.

Submodules