Packaging strategy "Calculate" always returns "There are no shipping rates available for this address."

Created on 4 June 2020, over 4 years ago
Updated 6 December 2024, 16 days ago

Steps to reproduce:

  • Set "Packaging strategy" to "Calculate"
  • Perform a test checkout
  • When shipping rates are calculated it always fails with "There are no shipping rates available for this address."

Calculations are working for "All items in one box" and "All items in their own box"

Watchdog logs shows: "FedEx sent no response back."

πŸ› Bug report
Status

Active

Version

2.0

Component

Code

Created by

πŸ‡ΊπŸ‡ΈUnited States 3cwebdev

Live updates comments and jobs are added and updated live.
Sign in to follow issues

Comments & Activities

Not all content is available!

It's likely this issue predates Contrib.social: some issue and comment data are missing.

  • πŸ‡ΊπŸ‡ΈUnited States rhovland Oregon

    This also affects 2.x but the REST API responds with a much more useful error message:
    Total package count cannot exceed the limit of {PACKAGE_COUNT} packages.

    Examining the request sent I see:
    'groupPackageCount' => 98891

    There is only one package. Examining $requested_package_line_item->sequenceNumber the value is 1

    The group package count is set using $requested_package_line_item->setGroupPackageCount($count) and $count is calculated with static::calculatePackageCount($requested_package_line_item, $packages[$requested_package_line_item->sequenceNumber - 1]) which gives a result of 98891.

    This is a result of the default 1x1x1mm package being selected.

    If the configured box is smaller than the items going into it this math will work out a huge number of packages despite it being an impossible shipment.

    If we don't want to introduce anymore complexity into the Calculate option then at least the description needs to be changed to something like:
    "Calculate" will take the volume of the package type selected in this shipping method and divide it by the total product volume of the order. Fedex will return a single rate for the number of packages with the selected dimensions and weight evenly divided between them.

  • πŸ‡ΊπŸ‡ΈUnited States rhovland Oregon
Production build 0.71.5 2024