Announcement

Collapse
No announcement yet.

Order Line Totals Causing Strange (but repeatable) Crashing

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

    Order Line Totals Causing Strange (but repeatable) Crashing

    We have been experiencing certain orders crashing Sellerdeck, and we couldn't figure out what made these orders different from others until yesterday.

    The pattern in problem orders seems to be the line total, i'll give an example below:

    If you have a product costing £72.56 (any price between £72.53 and £72.57 inclusive also work), and start a new order (works with both orders placed online, and offline although offline is a quicker way of testing). When you try to place the item into the basket Sellerdeck will crash and you'll have to reload.

    If you run the order through the website you'll find you can download the order, but not open it.

    If you then change the price to £72.58 and try again it doesn't crash and lets you add the item.

    This works even if multiples of the product add up to the magic number (more I've found listed below), so having 2 x £36.28 will also cause the crash.

    I've tested this on both our current running site, and a completely fresh site, but it would be great if others could also test this out.

    Values I've found so far are:

    £72.56
    £104.55
    £1041.90
    £347.30

    #2
    The only time I've sen anything like this in the past has been when orders include details of a shipping charge that doesn't exist.

    There isn't anything about these orders that would break the shipping calculations is there? Or any other kind of order related charges / details / discounts etc?
    -----------------------------------------

    First Tackle - Fly Fishing and Game Angling

    -----------------------------------------

    Comment


      #3
      I can replicate the problem on the test site Sellerdeck has when you first install it, but i've also found that it's not always a line total problem.

      When testing the £347.30 line total the order doesn't crash until you add £8.75 shipping (our standard charge for items over 10kg) which suggests the crash also happens when any of the order value boxes reach a certain value.

      Have to say this is a very strange problem.

      Comment


        #4
        Well this sounded too strange not to give it a try and I was fully expecting it to work and that the problem was something very specific to your situation.

        Er, no. £72.56 on a clean 16.01 demo site (MOTO order) crashes Sellerdeck here too!

        I'm currently juggling that number in any way I can think of to see how it might break a field constraint or something.

        Findings so far:

        1) It's not shipping related as switching off shipping charges entirely does not resolve it.

        2) It also fails on 87.07 with a tax inclusive setting (i.e. the same line price as your 72.56 tax exclusive product); this is the case for both Simple and Advanced tax models. However it does not fail with 87.07 with Tax disabled entirely. It can be safely assumed that it's a bug in the tax calculation.

        3) This behavior is not evident in v14.03
        Andy Barrow
        http://www.codepath.biz
        T: 0161 870 6355

        Accredited Sellerdeck development partners since 2004.
        Data import / export and catalog management plug-ins.

        Comment


          #5
          if you can make an order total reach £427.26 inc VAT you'll get the same problem.

          Working out the VAT for each problem number you get a number ending in 1 (after rounding). No idea if that's relevant, but might be worth checking.

          Comment


            #6
            Originally posted by Dealec View Post
            if you can make an order total reach £427.26 inc VAT you'll get the same problem.

            Working out the VAT for each problem number you get a number ending in 1 (after rounding). No idea if that's relevant, but might be worth checking.
            I'd say that's too coincidental to ignore so possibly at the root of it. I've made SD aware of this so I doubt there's much more to be done until someone there has had a look at the code.
            Andy Barrow
            http://www.codepath.biz
            T: 0161 870 6355

            Accredited Sellerdeck development partners since 2004.
            Data import / export and catalog management plug-ins.

            Comment


              #7
              However it does not fail with 87.07 with Tax disabled entirely. It can be safely assumed that it's a bug in the tax calculation.
              Working out the VAT for each problem number you get a number ending in 1 (after rounding).
              So it could be a bug in the rounding algorithm sellerdeck are using for tax.

              I wonder if using a different rounding type works as a temporary work around.
              -----------------------------------------

              First Tackle - Fly Fishing and Game Angling

              -----------------------------------------

              Comment


                #8
                i couldn't replicate the problem with a 5p product, and that gave me exactly 1p VAT, but if i use a 105.05 product i get the crash.

                Comment


                  #9
                  Originally posted by Dealec View Post
                  i couldn't replicate the problem with a 5p product, and that gave me exactly 1p VAT, but if i use a 105.05 product i get the crash.
                  Yeah I can't seem to leave this alone :-) I've written a bit of code that generates a batch of products which all result in a xxx1 pence of VAT many work, many don't. Looking like it has to be in the higher range as well but still playing about with it.
                  Andy Barrow
                  http://www.codepath.biz
                  T: 0161 870 6355

                  Accredited Sellerdeck development partners since 2004.
                  Data import / export and catalog management plug-ins.

                  Comment


                    #10
                    Originally posted by Mike Hughes View Post
                    So it could be a bug in the rounding algorithm sellerdeck are using for tax.

                    I wonder if using a different rounding type works as a temporary work around.
                    Could well be so, Mike. I'm just running some numbers to see if the error is specific to which direction the rounding takes, or if it's a specific offset from zero. Hope to know more soon.
                    Andy Barrow
                    http://www.codepath.biz
                    T: 0161 870 6355

                    Accredited Sellerdeck development partners since 2004.
                    Data import / export and catalog management plug-ins.

                    Comment


                      #11
                      I've asked for this to be investigated ASAP. Which version of SellerDeck are you using, please?
                      Bruce Townsend
                      Ecommerce Product Manager
                      Sellerdeck Ecommerce Solutions

                      Comment


                        #12
                        The £105.05 product gives you exactly £21.01 in tax, so shouldn't cause any rounding.

                        At least things are starting to look less random compared to what i had yesterday

                        Comment


                          #13
                          I'm using 16.0.0 multiuser.

                          Comment


                            #14
                            Originally posted by brucet View Post
                            I've asked for this to be investigated ASAP. Which version of SellerDeck are you using, please?
                            16.01 here Bruce. As per earlier post, 14.03 does not seem to be affected.
                            Andy Barrow
                            http://www.codepath.biz
                            T: 0161 870 6355

                            Accredited Sellerdeck development partners since 2004.
                            Data import / export and catalog management plug-ins.

                            Comment


                              #15
                              I didn't get to the bottom of the exact criteria to cause a failure as there is a lot of variance in the results, although as Andrew suggested earlier, VAT calculations ending in 1p do seem to be a common factor amongst values known to fail.

                              Adjusting the rounding method appears to have no effect.
                              Andy Barrow
                              http://www.codepath.biz
                              T: 0161 870 6355

                              Accredited Sellerdeck development partners since 2004.
                              Data import / export and catalog management plug-ins.

                              Comment

                              Working...
                              X