Rounding issue on purchase invoice

I received an invoice from a supplier. The invoice has rounding and I can’t encode it in tryton without rounding issue.

On one line, I have:

  • quantity: 377 units
  • unit price (without tax): 0.46
  • unit price (tax incl): 0.55
  • total price (without tax): 172.79
  • total price (tax incl): 207.35

In Tryton, I can’t simply record it (I have 4 decimals):

  • 377 x 0.4583 = 172.7791 (172.78)
  • 377 x 0.4584 = 172.8168 (172.81)

How to manage such case ? For now, I am thinking about using a “dummy” product for such cases.

I think the supplier invoice is done using price with taxes (377 x 0.55 = 207.35 without rounding issue), and number “without tax” are just computer for display. But I am recording “without tax” and rounding is bad.

For me, the important is that you have the same total and tax amount as the supplier.
So you should use the lower unit price and edit the tax line to match the numbers.
(The supplier is rounding too much the unit prices)

by simply using the lower unit price, the total price is wrong. and from Invoice, I could only edit the tax amount (and here, the base is wrong too).

do you mean changing base and tax on tax line ? I think it is possible only from the MoveLine, and not from InvoiceLine. so I should first validate the invoice, edit the move and next post the invoice ?

You can only change the tax amount.

The base is not so important as we can see that the amount of the supplier are wrong.
So if you do not want to increase the unit price precision, I would fill: 377 x 0.4583 = 172.7791 and set the tax amount to get the total of 207.35.

Can’t you just change the text of the line with a “lot of 377 products”, quantity 1, and unit price 172.79 ?
or add a line with text “supplier’s invoice rounding error” and put your cents here ?

Not if it is managed by a purchase or if he wants to link them to stock moves.

I think it is also a valid option which is similar to the tax editing.

Legally, i can’t change the tax. I have to use to one on the invoice, even if the tax is wrong (and if really wrong I have to ask supplier to credit and invoice again).

I am managing stock, so I need the real quantity. I think it could be possible with specific unit for “lot of 377 products” but I don’t want to create such units for each invoice…

it is what I intent to do. But I can’t simply use the usual account for such rounding error (658 in french chart of accounts) as the account isn’t configured for use in InvoiceLine (and diverging from the module by overloading configuration makes any upgrade more complex with manual setup).

Then you could fill the invoice with the 1 cent difference and create an accounting move to rectify the payable.
I’m wondering if we should not have an extra field to book such rounding issue of untaxed amount (as we allow for tax amount).