Your cart is empty

2 years ago
I have read all the posts I can find about empty carts. Here is my scenario.
SSL enable in "store" setting - cert good, no errors or warnings. Machine key is in place and NOPCommerce acknowledges that. Customers are getting your cart is empty and it is impossible to clear the error once they start getting it. Note: Guest users are NOT allowed access to cart with ACL. All users of the website are set up in advance with a user ID and customer role. The general public able to browse but can't see pricing or order.

Symptoms: Today it is happening a lot. Today's error is showing the user is Guest. Other days it has shown the customer's email address. We even have gotten it while impersonating the dealer.

NO modifications whatsoever to the source code. The is plain jane out of the box NopCommerce 3.90.

1) Customer logs out and back in
2) Customer clears cache
3) Customer clears site cookie
4) Customer clears all cookies.
5) Remove the item from the cart and re-add it
6) Change the qty of the cart
7) Delete the cart from SQL side.

Only thing that works is a different browser.

HTTP -> Https redirect rule
   <rule name="HTTP/S to HTTPS Redirect" enabled="true" stopProcessing="true">
        <match url="(.*)" />
        <conditions logicalGrouping="MatchAny">
          <add input="{SERVER_PORT_SECURE}" pattern="^0$" />
        <action type="Redirect" url="https://{HTTP_HOST}{REQUEST_URI}" redirectType="Permanent" />

Auth section:
<forms name="NOPCOMMERCE.AUTH" loginUrl="~/login" protection="All" timeout="43200" path="/" requireSSL="false" slidingExpiration="true" />

Log level: Warning
Short message: Your cart is empty
Full message: System.Exception: Your cart is empty at Nop.Web.Controllers.CheckoutController.OpcSaveBilling(FormCollection form)
IP address
Customer  Guest
Page URL:
Referrer URL:  /onepagecheckout
Created on: 5/21/2018 5:21:51 PM
2 years ago
Just some more information, the customers show they are logged in. But NOPCommerce thinks they are a Guest? It is creating guest customers for them when this happens everytime the error occurs.
2 years ago
I am using one page checkout and if I disable that, it allows the customer with the error to check out. As soon as I put one page checkout back it was broken for the same customer and same cart again.
2 years ago
Hoping someone can help with this. I have turned off one-page checkout and it seems to have fixed one user that could not complete an order. Hoping it works on them all. But this is a short-term fix and I would really like to understand the root cause of my issue.

Again, all users must log in to create a cart, and yet when they go to check out the error is logged as a guest and the error occurs at billing mostly. Sometimes it shows their customer id and they make it to shipping information.
2 years ago
I'm having the same issue as yours, using the OPC that comes with nopCommerce, hopefully someone or nopCommerce team could give us a nice solution to resolve this issue permanently.
1 year ago
Did anyone find a solution to this? We are getting lots of these errors too (the customer is being charged at the payment end):

Your cart is empty

Full message  
System.Exception: Your cart is empty
   at Nop.Web.Controllers.CheckoutController.OpcSavePaymentInfo(IFormCollection form)

1 year ago
Anyone find a solution for this?
1 year ago
Unfortunately not! The only thing we found was that it only happened with guest checkout, so disabled it.

Not ideal and something we need to address - had zero response from any one at nop!!
1 year ago
I just ran into this issue yesterday and looking for a solution...I'll keep posted if I find anything.
1 year ago
My client reported this starting to happen about 3 weeks ago, all of a sudden without any code changes.

Almost the exact steps provided above (THANK YOU jmhpickpro for your tireless and thorough troubleshooting & documentation).

I also disabled Guest checkout, but now they are still getting calls from registered users -- We are also using One-page checkout, because the other checkout method was throwing an error (I think related to the api??) so we switched.

Nop 4.0