Error - There is an error with the discount: Id can't be found

Highlighted
Shopify Partner
1 0 0

I'm trying to create tiered discount here. In the script I reject the discount code if the discount from the script is applicable. To test the script from the app, I input a discount code which is already available in the store. Running the script throws me this error 

"here is an error with the discount: Id can't be found"

Is this a problem with Shopify?

0 Likes
Highlighted
Tourist
3 0 0

+1, I'm having a similar issue.

It also shows an error in the side of the script console that reads:

discount id can't be found (Your Cart)
discount id can't be found (Empty Cart)
discount id can't be found (No Customer)

Customer and cart are both set in testing console, along with discount code. Can provide more details if needed.

0 Likes
Highlighted
Shopify Partner
8 0 1

+1

Also having this issue.

Any luck so far with solving this issue?

0 Likes
Highlighted
Tourist
3 0 0

Sadly not yet here! I just noticed Jason has replied to a similar thread, have followed up there too.

0 Likes
Highlighted
Shopify Partner
8 0 1

Just an update after having a follow up with out Shopify rep.

The bug is only present in the editor itself when debugging, and your script will work in the cart/checkout on the front end.

Quite annoying, but it will get the job done if you need make the script work and test it out on a test store.

0 Likes
Highlighted
Shopify Expert
20 0 1

I'm getting the same error still. It occurs for me whenever I enter a free shipping discount code into the Script Input, even if the discount code has no requirements to use and even if the script itself is basically blank:

Output.shipping_rates = Input.shipping_rates

Which leads me to believe this is a Shopify bug that can't handle Free Shipping discount codes in the Script Editor input for testing, for some reason. I hope it is fixed soon.

0 Likes