product tags + line item properties in shopify scripts

Solved
bestrada
Tourist
12 2 0

https://mintandlily.com/products/mon-amour-name-necklace

I have a problem with my shopify scripts as it relies on product tags. I suspect that there is a problem with shopify scripts whenever line item properties are introduced. As noted in partner slack community, it is not possible to add line item properties in the script editor so I don't know how to test or produce useful logging to figure out what is wrong. How does Shopify recommend I troubleshoot my script.

Repro Steps:

  1. Visit the link above
  2. Add one necklace to the cart, typing in "Test" as your personalization
  3. Increase the quantity in the cart to 3
  4. observe that the "Gift & Save" discount via shopify script applies
  5. empty the cart
  6. Add a necklace in one-at-a-time to the cart, each with a different personalization
  7. observe that the "Gift & Save" discount is not applied

I feel uncomfortable pasting the source code of my script here publicly, but I am open troubleshooting this bug privately with Shopify.

0 Likes
bestrada
Tourist
12 2 0

This is an accepted solution.

Per Jake Olney's suggestion, I was able to troubleshoot my bug by assigning hard-coded properties in my script manually and find the bug. This problem is solved.

0 Likes