I’m testing with partial position closing and I tested the following code. It should be impossible to close half of any position if the remainder left on the market is less than 0.2 but when I check the orders list it shows positions with a size of less than 0.2 being closed.