apply_even_split in discounts incorrectly splits discount

Create issue
Issue #909 resolved
udbhav created an issue

Say I have a discount total of $10 which applies to 3 items in my cart. Under the current behavior, apply_even_split in product/ would discount $3.33 from each item, giving a total discount of $9.99, rather than $10.

Comments (4)

  1. Tay Ray Chuan
    • changed status to open

    This sounds serious.

    We should check if we have a test for this in satchmo before confirming.

  2. Tay Ray Chuan

    Turns out that this is actually expected behaviour.

    For example, see the test product.CalcFunctionTest.testThirds.

  3. Tay Ray Chuan

    (Assigning to Chris so that this gets more visibility.)

    I've published a fix for this as 1457:efd4515f00b1.

    In a sense, this bug has become expected behaviour, so I suspect a fix would break things. I think a note in the release notes would be appropriate, but I'll leave this decision to Chris.

  4. Log in to comment