I had confirmed this issue with Jacques-Etienne before he reported it, this 
should have been Confirmed from the start, sorry for the delay.
Note: clients do need minor corrections too due to the implicit naive rounding 
they perform when you enter a value with too many decimal digits, for example 
1.145 when the decimal precision is set to 2 digits. Removing the implicit 
client-side rounding is an option.

** Changed in: openobject-server
       Status: New => Confirmed

** Changed in: openobject-server
    Milestone: None => 6.1

** Changed in: openobject-server
     Assignee: OpenERP Publisher's Warranty Team (openerp-opw) => OpenERP's 
Framework R&D (openerp-dev-framework)

** Summary changed:

- rounding error
+ Incorrect float rounding when setting float field with too high precision

** Also affects: openobject-server/6.0
   Importance: Undecided
       Status: New

** Changed in: openobject-server/6.0
   Importance: Undecided => High

** Changed in: openobject-server/6.0
       Status: New => Confirmed

** Changed in: openobject-server/6.0
    Milestone: None => 6.0.4

** Changed in: openobject-server/6.0
     Assignee: (unassigned) => OpenERP Publisher's Warranty Team (openerp-opw)

** Also affects: openobject-client
   Importance: Undecided
       Status: New

** Changed in: openobject-client
   Importance: Undecided => Medium

** Changed in: openobject-client
       Status: New => Confirmed

** Changed in: openobject-client
    Milestone: None => 6.1

** Changed in: openobject-client
     Assignee: (unassigned) => OpenERP sa GTK client R&D (openerp-dev-gtk)

-- 
You received this bug notification because you are a member of C2C
OERPScenario, which is subscribed to OpenERP Project Group.
https://bugs.launchpad.net/bugs/882036

Title:
  Incorrect float rounding when setting float field with too high
  precision

Status in OpenERP GTK Client:
  Confirmed
Status in OpenERP Server:
  Confirmed
Status in OpenERP Server 6.0 series:
  Confirmed

Bug description:
  Concerns 6.0 and trunk.
  If you define a precision of 0.01, the rounding of 0.125 must be 0.13 and not 
0.12. The error is in the call of the format string "%.2f"%val which introduces 
a mathematical error. The round function must be called to apply the correct 
rounding before formatting the string. It should be:
  "%.2f"%round(val*100)/100
  Fix class digits_change of class float in the server. BUT fix also the gtk 
client AND web client as they all have that error (I let you find the right 
line)

To manage notifications about this bug go to:
https://bugs.launchpad.net/openobject-client/+bug/882036/+subscriptions

_______________________________________________
Mailing list: https://launchpad.net/~c2c-oerpscenario
Post to     : [email protected]
Unsubscribe : https://launchpad.net/~c2c-oerpscenario
More help   : https://help.launchpad.net/ListHelp

Reply via email to