One thing you could check is whether rounding is preventing the PO from appearing fully invoiced. For example, suppose the PO had one line for quantity 3, with 3 separate distributions for quantity 1 each. Then you receive quantity 1 and invoice before delivering that 1 part to on hand inventory. The invoice will be for quantity 0.333333333333333 on each of the three distributions. If you later receive the other 2, then you will get another invoice with quantity 0.66666666666666 on each of the three distributions. The invoices are each validated, however the sum of the invoiced quantity is now 2.999999999999999, which is not 3, so the PO cannot be finally closed.
If this is useful or resolves your issue, please use the buttons on this response to mark it 'helpful' or 'correct'