- Issue created by @scottsawyer
- πΊπΈUnited States scottsawyer Atlanta
Ok, first hitch:
The service "commerce_cart_advanced.hook.cart_item_form_alter" has a dependency on a non-existent service "commerce_pri
ce.number_formatter_factory". Did you mean one of these: "commerce_price.number_format_repository", "commerce_price.num
ber_formatter"?This is used in Drupal\commerce_cart_advanced\Hook\CartItemFormAlter. Checking into the replacement https://www.drupal.org/node/2975672 β .
- πΊπΈUnited States scottsawyer Atlanta
The merge request is working on my local. Please test and let me know.
- πΊπΈUnited States scottsawyer Atlanta
I just updated Drupal Commerce to 3.0.1, which introduces autowiring for the CartProvider, and breaks our AdvancedCartProvider.
The fix, thanks to the friendly folks on Slack, is to change the way CommerceCartAdvancedServiceProvider::alter method adds the database service.
Before:
$definition->addArgument(new Reference('database'));
to
$definition->setArgument('$database_connection', new Reference('database'));
- Status changed to Needs work
14 days ago 2:39pm 20 May 2025 - πΊπΈUnited States scottsawyer Atlanta
Commerce 3.0.2 adds a return type to Drupal\commerce_cart\Plugin\Block\CartBlock::build(): array. Need to update
Drupal\commerce_cart_advanced\Plugin\Block\CurrentCartBlock::build() - πΊπΈUnited States scottsawyer Atlanta
Per https://www.drupal.org/node/3517855 β
If you have subclassed the cart block and overridden the getCartViews() method, this method has been moved to the new service class: CartLazyBuilders.
Maybe we should extend this class and point the generatePlaceholder LazyBuilder to the new service rather than swapping the service entirely to keep this functionality contained within the module to reduce the chance of side effects?