Stock ledger and Balance Qty not correct

Erpnext v9 and on v10.0.18 (master) the same is happening
on V9 for a single item that was sold on POS
imageWarehouse Stock UOM Qty Balance Qty Incoming Rate Valuation Rate Balance Value Voucher Type Voucher #
Farmacia - FX Unit 50 50 30 30 1500 Purchase Invoice PINV-00054
Farmacia - FX Unit -50 0 0 30 0 Stock Entry STE-00752
Loja - FX Unit 50 50 30 30 1500 Stock Entry STE-00752
Loja - FX Unit -1 33 0 30 990 Sales Invoice SINV-18/43766
Loja - FX Unit -1 14 0 30 420 Sales Invoice SINV-18/43823
Loja - FX Unit -1 15 0 30 450 Sales Invoice SINV-18/43494
Loja - FX Unit -1 16 0 30 480 Sales Invoice SINV-18/43499
Loja - FX Unit -8 17 0 30 510 Sales Invoice SINV-18/43546
Loja - FX Unit -6 25 0 30 750 Sales Invoice SINV-18/43693
Loja - FX Unit -2 31 0 30 930 Sales Invoice SINV-18/43767

on V10 for the same item that was created and sold on POS

Any advise on how to solve this would be great …
If you are on the POS and you sell the same item one after the other for the reason the system gets crazy and either does not decrease or it ADDs …

did you test it in the latest version? Perhaps just updating to the latest version might resolve it.

Not yet but will give a try. Thanks