Support for Drupal 7 is ending on 5 January 2025—it’s time to migrate to Drupal 10! Learn about the many benefits of Drupal 10 and find migration tools in our resource center.
Problem/Motivation
Attempting to migrate Drupal 7 Ubercart to D9 Commerce using Drush produces an error with the tax rate.
In Adjustment.php line 86:
The provided percentage "0.0775" must be a string, not a float.
Steps to reproduce
Migrate Drupal 7 site with Ubercart and taxes setup
Proposed resolution
Cast the tax rate to a string.
Remaining tasks
User interface changes
API changes
Data model changes
Issue fork commerce_migrate-3262113
Show commands
Start within a Git clone of the project using the version control instructions.
Or, if you do not have SSH keys set up on git.drupalcode.org:
Comments
Comment #3
quietone CreditAttribution: quietone at PreviousNext commentedJust updating the title.
Comment #4
DamienMcKennaComment #5
quietone CreditAttribution: quietone at PreviousNext commented@retiredpro, thanks for the report and the patch.
I am not able to generate a float for the tax_rate, it is always stored as a string in a data blob. Can you provide some more details? What other commerce modules are you using? Was this perhaps a custom migration?