discountApplicationStrategy with `All` Type not working when using with multiple variants

I have a app that with a function that will have a output of below:

{
  "discountApplicationStrategy": "ALL",
  "discounts": [
    {
      "value": {
        "percentage": {
          "value": 20
        }
      },
      "targets": [
        {
          "productVariant": {
            "id": "gid://shopify/ProductVariant/46960668311869",
            "quantity": 5
          }
        }
      ],
      "message": "Volume discount"
    },
    {
      "value": {
        "percentage": {
          "value": 10
        }
      },
      "targets": [
        {
          "productVariant": {
            "id": "gid://shopify/ProductVariant/46960668311869",
            "quantity": 3
          }
        }
      ],
      "message": "Volume discount"
    }
  ]
}

This do working as expected, the two discounts is applied correctly, the following is the result

but when it involved with multiple variants, the second’s discount is not applied correctly, the following is the output and result

{
  "discountApplicationStrategy": "ALL",
  "discounts": [
    {
      "value": {
        "percentage": {
          "value": 20
        }
      },
      "targets": [
        {
          "productVariant": {
            "id": "gid://shopify/ProductVariant/46960668311869",
            "quantity": 3
          }
        },
        {
          "productVariant": {
            "id": "gid://shopify/ProductVariant/46960668377405",
            "quantity": 2
          }
        }
      ],
      "message": "Volume discount"
    },
    {
      "value": {
        "percentage": {
          "value": 10
        }
      },
      "targets": [
        {
          "productVariant": {
            "id": "gid://shopify/ProductVariant/46960668311869",
            "quantity": 3
          }
        }
      ],
      "message": "Volume discount"
    }
  ]
}

Do anyone faced the same issue?
Do let me know if I am doing something wrong on the output or if there is a bug here.

I did try with couple different structure(eg: each variants in different discount individually, and each discounts have same type of variants but put zero if no discount, but zero is not allowed in quantity)

but still not working yet