openerp-expert-accounting team mailing list archive
-
openerp-expert-accounting team
-
Mailing list archive
-
Message #01395
Re: [Bug 865387] Re: wrong currency rounding
2011/11/4 Olivier Dony (OpenERP) <865387@xxxxxxxxxxxxxxxxxx>:
>
> We don't use Decimal for OpenERP, our floating point calculations are all performed with floats, and we have appropriate solutions for all cases based on floats. So for consistency, please do not introduce the use of Decimal in patches.
> For more info on the everlasting Float vs. Decimal discussion, see [1].
>
> [1] https://lists.launchpad.net/openerp-expert-accounting/msg00067.html
Hello Olivier,
I have one more doubt about floats: how could I manage this
>>> round(2.675, 2)
2.67
?
I need 2.675 to become 2.68, and python suggests to use decimal for that:
http://docs.python.org/tutorial/floatingpoint.html#tut-fp-issues
(this is why I was using decimal in 'l10n_it' too)
Thanks
--
Lorenzo Battistini
Agile Business Group sagl http://www.agilebg.com
Follow ups
References