Product Properties Duplicating After Checkout

Pippa_Ridley_-_
Shopify Expert
222 0 11

Hi. So we're having some trouble with a development site we're implementing a custom solution for.

The general idea is we have a product, which the customer can enter a width and a height, then upload an image. These three items of data are added to the product as a property - the image is converted to it blob text form and we add an additional property - a unique reference, to make sure the instance of the product is unique in the cart. 

When sending through one product everything is fine. However with 2 products the item properties of the second product are becoming a duplicate of the first product but only at the point where the order actually enters shopify.

Please see screenshot1 https://www.dropbox.com/s/t1j6jf7c2m1r680/screenshot1.png?dl=0 – you can see that in the cart there are 2 separate instances of the product with different unique reference numbers and different width and height properties. Doing an ajax cart/get and outputting to console, I can see that the _BlobText property is also different for each item.

Screenshots 2 https://www.dropbox.com/s/e40lo5lzqcrjt64/screenshot2.png?dl=0 and 3 https://www.dropbox.com/s/aty883zvzc0ahou/screenshot3.png?dl=0 – all the way through the checkout process we still see 2 separate instances with different width and height properties. Even at the order confirmation stage (screenshot3) they are different.

Screenshots 4 https://www.dropbox.com/s/l5nc0p22fju8fpk/screenshot4.png?dl=0 and 5 https://www.dropbox.com/s/53hcfudcj68cb8u/screenshot5.png?dl=0 – however, looking at the order in the backend, the width, height and unique reference are now suddenly exactly the same for both items. The image text blog is also the same. I don’t understand how this can be the case when they were showing different width and height even on the order confirmation screen, but are now suddenly showing the same width and height.

Screenshot 6 https://www.dropbox.com/s/li11a1j514ad8i1/screenshot6.png?dl=0  – I then tested an order of two of the same product but with different width, height and unique references but WITHOUT sending the blob and this has come through as expected – the properties remain unique.

It appears the problem is being caused by the blob but I don’t understand what is happening or why. The blob is being sent fine with no error messages or timeout messages, and when we convert the blob back into an image at the other end it looks exactly as expected – nothing is being lost. The only problem is that if we send 2 items with blobs at the same time the entire item properties of the second item become replaced with the same item properties as the first item?

I'm not sure if this is a weird bug or if the problem is we're sending too much information through? It would just be helpful to know exactly what the problem is so we can find a way around it. I know we could allow people to upload images at the time they're on the product page and save them on an external server somewhere but we're just trying to prevent people from being able to upload anything directly to our server for security reasons. 

If you need help with a Shopify customisation, drop me an email on pipparose@etempa.co.uk
0 Likes
awwdam
Shopify Staff
Shopify Staff
152 16 12

Hey @Pippa_Ridley_-_,

Would you be able to provide me with one of the x-request-id headers returned for an order where the unexpected functionality was present? - Cheers!

awwdam | API Support @ Shopify
- Was my reply helpful? Click Like to let me know!
- Was your question answered? Mark it as an Accepted Solution
- To learn more visit Shopify.dev or the Shopify Web Design and Development Blog

0 Likes
Pippa_Ridley_-_
Shopify Expert
222 0 11

Hi 

Thanks so much for your reply. So in the course of submitting the order and getting to the confirmation page there were 4 different instances of the processing file each with a different x-request-id? I'm not sure which one you need so I've copied them all.

x-request-id: ff8f4d53-c686-4d6f-b24b-35ebf6d3b29a
x-request-id: 5b57c1df-3d93-42ac-aeaa-a9b27dbc0846
x-request-id: 54acde98-8bce-4350-8708-a390d20888a0
x-request-id: a0b2813a-6306-4fa2-9946-4359f1a2e2f1

If you need help with a Shopify customisation, drop me an email on pipparose@etempa.co.uk
0 Likes