Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

500 Error Graphql - Buy One Get One Discount breaks cart #926

Open
4 tasks done
shawngrona opened this issue Nov 13, 2022 · 9 comments
Open
4 tasks done

500 Error Graphql - Buy One Get One Discount breaks cart #926

shawngrona opened this issue Nov 13, 2022 · 9 comments

Comments

@shawngrona
Copy link

shawngrona commented Nov 13, 2022

Bug details

Describe the bug
Shopify Buy One Get One discount breaks cart functionality.

Steps to reproduce:

  1. Create a collection listing all products example
  2. Create a Buy One Get One Discount example
  3. Using this example code in react-js-buy folder, add a product that is part of the Buy One Get One discount (eg "Foundations in MDMA Safety, Therapeutic Applications & Research") to cart multiple times

Expected:

Cart should show line items with quantity.

You should be able to add or remove the line items from cart.

Actual:

Strange presentation in the cart with same variant split into multiple line items.

You're unable to remove line items from the cart which are involved in the BOGO discount. 500 error from the graphql endpoint for example:

index.js:4078 Uncaught (in promise) Error: [{"message":"Internal error. Looks like something went wrong on our end.\nRequest ID: 9ef6a61e-3635-4426-b263-b7c59582e46f (include this in support requests).","extensions":{"code":"INTERNAL_SERVER_ERROR","requestId":"9ef6a61e-3635-4426-b263-b7c59582e46f"}}]

Code Example:
Here is a minimum reproducible example code based off of the storefront-api-examples repo

Video Example:
Here is a Loom video which demonstrates the issue

Environment (please complete the following information):

  • OS: Mac
  • Browser Chrome, Safari, Any
  • SDK Version 2.17.1

Additional context
Here is a minimum reproducible example code based off of the storefront-api-examples repo

Bug Report Checklist

  • I have read and agree to the CODE_OF_CONDUCT.md
  • I have read the CONTRIBUTING.md guidelines.
  • I have provided a detailed description of the bug, including code samples, and/or network data.
  • I have provided information about my development environment, including SDK version.
@whitesunset
Copy link

whitesunset commented Nov 14, 2022

Same issue here with Cart + Discount code applied after I tried to remove line item from cart. Any help?

@shawngrona
Copy link
Author

Thanks @whitesunset. I opened a support ticket by requesting a callback, sat on hold for half an hour, they said they'd get back to me ticket 34237990.

I expect this will take a while to get shopify to own this issue... i got significant pushback about this being "a third party theme and not their issue" while escalating through support.

i'll follow up here as i follow up on that ticket

@shawngrona
Copy link
Author

Shopify support still telling to contact the third party theme developer. Very frustrating to receive this level of support, we've paid shopify a lot of money over the years - they get a cut of every sale.

Anyone reading these github issues?

@shawngrona
Copy link
Author

Opened another issue over here in Shopify community land

@ayohdev
Copy link

ayohdev commented Nov 25, 2022

Same issue here with Cart + Discount code applied after I tried to remove line item from cart. Any help?

We are seeing the same issue when trying to remove a lineItem from the cart (when it happens to be the last line item left in. the cart)

We are seeing this error in gatsby

Screen Shot 2022-11-25 at 12 18 25 PM

@j-Riv
Copy link

j-Riv commented Nov 28, 2022

I'm seeing a similar 500 error when trying to use removeLineItems with a line item that has an automatic discount (amount off products).

@lamellama
Copy link

I'm sure most people have figured this out already but I have had to switch from removeLineItem to updateLineItems with a quantity of 0

@johncraigcole
Copy link

Hey @shawngrona a fix was deployed for the problem with checkoutLineItemsRemove please let me know if you continue to experience the issue.

@Hahlh
Copy link

Hahlh commented Dec 20, 2022

@johncraigcole

As a late confirmation:
It was resolved for us. Thanks a lot for the fix!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

7 participants