Issue documented in this support thread on UC main site.
In summary, if you have your checkout panes arranged in a way that the Calculate shipping cost pane comes before the Delivery information pane, the shipping quote modules do not have the necessary delivery information recorded in the order object passed to them in uc_cart_checkout_form_validate
, resulting in failed quotes and the above-referenced message.
It appears that depending on the way flat-rate shipping methods are configured, they might still work (as long as there are no CA's defined based on the delivery location).
Moving the Calculate shipping cost pane after the Delivery information pane allows the order to process normally with quotes.
I'm working on a site using UPS, Fedex, and USPS integration as well as several flat-rate methods and am seeing the same behavior on all the live-quote shipping methods when they are selected and clicking the "Review Order" button.
Comments
Comment #1
TR CreditAttribution: TR commentedNot sure what you're asking for here - shipping quotes obviously need to know the destination address before they can return a meaningful response. Once you've filled in the destination the quotes should be generated automatically regardless of order of the panes.
Comment #2
arpieb CreditAttribution: arpieb commentedYep, I agree with you completely. Let me walk you through my scenario:
On examining the order being processed after clicking "Review order" you will see that the panes are processed in the order that they are arranged to appear on the page via the checkout pane admin page. What this means is that if the shipping quote pane appears before the delivery info pane, the form validation function has no delivery information to pass to the quote pane's validation handler - the values with keys beginning with "delivery_" are not populated in the order object that is passed to all panes weighted to appear before the delivery info pane. Quotes fail, checkout validation fails, and our favorite error msg appears.
Switch the shipping quotes pane to be weighted to appear after the delivery info pane, and the order object passed to the quote pane validation hook has what it needs to fetch quotes.
This is not a "support request" but a "bug report" - if UC allows you to rearrange checkout panes, then the checkout validation logic should not hinge on what order the panes are arranged.
Comment #3
arpieb CreditAttribution: arpieb commentedHere's the function in it's entirety that is causing the problem:
Note that the iteration through the $form_state['values']['panes'] array just takes the panes in whatever order the array has been built in... I was seeing them in the same order that they were presented on the checkout page, but not sure if D6 core FAPI is populating that array in the same order it was created by the original FAPI form construction, or if it was a coincidence. Might also explain why that error occurs so inconsistently and has proven to be so hard to pin down.
Comment #4
longwaveI guess if #1290000: Add 'prepare' checkout pane callback. was backported to D6, it would solve this problem.
Comment #5
longwaveThis is the same as #1453306: Selecting an address from the drop down at checkout doesn't trigger shipping costs or triggers incorrect shipping costs, and it is much more likely to be fixed in 7.x-3.x first.