Saleor Core: the high performance, composable, headless commerce API.
Python cartcheckoutcommercecomposablee-commerceecommercegraphqlheadlessheadless-commercemultichannelomsorder-managementpaymentspimpythonshopshopping-cartstore
Always cast database ID to int in dataloader (#9340)
Marcin Gębala841f9a6ae96d
diff --git a/saleor/checkout/fetch.py b/saleor/checkout/fetch.pyindex 17ed7e262f..924243e16b 100644--- a/saleor/checkout/fetch.py+++ b/saleor/checkout/fetch.py@@ -134,7 +134,7 @@ class ShippingMethodInfo(DeliveryMethodBase):@propertydef delivery_method_order_field(self) -> dict:if not self.delivery_method.is_external:- return {"shipping_method_id": self.delivery_method.id}+ return {"shipping_method_id": int(self.delivery_method.id)}return {}def is_valid_delivery_method(self) -> bool:diff --git a/saleor/graphql/checkout/tests/test_checkout_complete.py b/saleor/graphql/checkout/tests/test_checkout_complete.pyindex 5c843aa4e7..173c0cc1e9 100644--- a/saleor/graphql/checkout/tests/test_checkout_complete.py+++ b/saleor/graphql/checkout/tests/test_checkout_complete.py@@ -33,11 +33,19 @@ MUTATION_CHECKOUT_COMPLETE = """mutation checkoutComplete($token: UUID, $redirectUrl: String) {checkoutComplete(token: $token, redirectUrl: $redirectUrl) {order {- id,+ idtokenoriginalorigin- },+ deliveryMethod {+ ... on Warehouse {+ id+ }+ ... on ShippingMethod {+ id+ }+ }+ }errors {field,message,