JPY and other currencies now represented differently

Solved

JPY and other currencies now represented differently

ShopDoctors
Shopify Partner
46 2 15

In the past the JPY currency in the cart data was represented like so:

1200 would refer to ¥12. We've done things with Shopify for 4 years and it's worked like this until now.

 

We are noticing today that this is no longer the case (maybe it changed earlier?). We now see 12 in the cart data when it refers to ¥12.

 

I understand the idea that JPY doesn't have cents, but this is causing an unimaginable number of problems for shops that sell in JPY - due to wrong theme display, wrong app widgets display, wrong calculations in javascript files using cart data, wrong comparisons in javascript, and the list goes on and on. 

 

Whoever made this decision has broken half of Shopify for the affected shop owners. Will this change be reverted?

Accepted Solution (1)

tieu
Shopify Partner
4 1 2

This is an accepted solution.

looks like they rolled this back!

View solution in original post

Replies 6 (6)

gr_trading
Shopify Partner
1919 145 199

Hi @ShopDoctors ,

 

if this was working fine earlier, you should try by disabling the apps one by one and check.

 

Most of time these error are due to app updates.

For any custom development WhatsApp or connect at Email ID: [email protected] for quick consultation. | Shopify Free codes
To support Buy Me a Coffee
ShopDoctors
Shopify Partner
46 2 15

You probably need to take a look at the response of all cart.js storefront API endpoints.

 

We have automated integration tests running against Shopify’s APIs to catch issues like this. Before the change you’d see price: 1200; after the change it’s now price: 12. This is only happening for less than 30 currencies. All others still operate the same way as before.

 

Shopify seems to no longer follow open closed principle. Couple months ago they broke draft orders, now this. At least they made a good decision and fully reverted their breaking changes to draft orders. I really hope they understand what they’ve done now as well. 

eugals
Shopify Partner
3 0 3

Would be great to read some reaction on this from Shopify devs please.

This has become a huge, unexpected and unannounced (?) problem for our app.

Is there at least a way to properly detect such currencies from JS/liquid at present?

 

I'm looking at https://shopify.dev/changelog/, but I don't see a single word about this formatting change there, or am I missing something?

tieu
Shopify Partner
4 1 2

we're also experiencing the same thing and couldn't find any other places mentioning this 😕 

ShopDoctors
Shopify Partner
46 2 15

We also spoke to people over at Shopify Slack. No response anywhere. Can you please advise what we need to do? We see that the cart.js data was changed, the liquid data was changed, but at the same time the cart data loaded into Shopify Functions still has the original format. What is the plan? Is this being reverted? Is this being fully deployed?

tieu
Shopify Partner
4 1 2

This is an accepted solution.

looks like they rolled this back!