Support for Drupal 7 is ending on 5 January 2025—it’s time to migrate to Drupal 10! Learn about the many benefits of Drupal 10 and find migration tools in our resource center.
There seems to be a problem with Commerce Kickstart 2.51 update. I have two sites both of which are running Drupal 7.56. Both have received updates [site one: CK 2.49 to 2.51] and [site two: CK 2.50 to 2.51]. All of a sudden both of the sites are having issues displaying shopping cart items to anonymous users. Besides the regular updates of CK, no other permissions have been changed or modules updated.
If I may add, when an item is added;
- Shopping Cart Modal pops up for anonymous user, but no items is listed in pop-up window
- When Anonymous user go to the shopping cart page, it says the shopping cart is empty
- Despite #1 and #2, when an admin goes to the active order page
admin/commerce/orders
, one can see the anonymous shopping cart items
I've come across similar post online but here are my take on those solutions;
- They suggest; Anonymous user role has not been deleted.
It is still intact in the database - They suggest: Change permission to allow Anonymous Users to View Any Product Type.
I'm reluctant to do this as it's a security risk in my opinion - They suggest: Change settings for multiple views, by disabling SQL Rewrite
This is also a security risk as Drupal tells you this when you try to disable SQL Rewrite
Thanks for your help in advance.
Comment | File | Size | Author |
---|---|---|---|
#13 | 2937535-13.patch | 214 bytes | mglaman |
Comments
Comment #2
wernerglinka CreditAttribution: wernerglinka commentedI struggled with the same issue. I tracked it down to a missing plugin folder in
/profiles/commerce_kickstart/modules/contrib/commerce/modules/cart/
the missing folder containsplugins/cart_provider/session.inc
which I think is needed to hold the session info.You can find the missing folder in a fresh download from here
Comment #3
npoku CreditAttribution: npoku commented@wernerglinka. Thanks, I'll give it a shot and let you know the outcome ASAP
Comment #4
wernerglinka CreditAttribution: wernerglinka commentedI am using Pantheon and just checked their upstream kickstart repo and the files are missing in the repo. I'll file an independent issue with that.
Comment #5
npoku CreditAttribution: npoku commented@wernerglinka. You were correct. That solved the problem. It seems that entire plugin folder
/profiles/commerce_kickstart/modules/contrib/commerce/modules/cart/plugins/cart_provider
was left out during the version 2.51 update.I'm also using Pantheon. Maybe that is where the culprit is :)
Comment #6
npoku CreditAttribution: npoku commentedComment #8
Jon Pollard CreditAttribution: Jon Pollard commentedHi, thought I'd add my experience. Updated to 2.51 yesterday and found the errors that led me here. I had downloaded the latest update and added it to my local development site. Checking the local git repo on my development server it does not have the commerce/cart/plugins directory - even though these files are on the server and not being ignored for any reason that I can see (i.e. .gitignore).
Doing some tests, a text file added anywhere below /profiles/commerce_kickstart/modules/contrib/ does not get picked up by git as a change - which does leave me wondering what else in that branch might be missing.
I'm not a git expert, but it looks like something fishy is going on and if it's happening to Pantheon too then I am in good company!
Comment #9
Jon Pollard CreditAttribution: Jon Pollard commentedI think I've found the culprit
/profiles/commerce-kickstart/.gitignore
2.49 version
2.51 has changed to this - 'modules/contrib' now set to be ignored
Is there a good reason for these last 4 entries to be ignored by git?
Comment #10
jphelan CreditAttribution: jphelan at One Thing commentedSame issue, spent about 10 hours trying to figure it out.
Comment #11
bojanz CreditAttribution: bojanz at Centarro commentedLet's figure out why that gitignore was changed, and what we need to do to prevent others from tripping on the same problem.
Comment #12
mglamanMy fault.
Comment #13
mglamanFix.
Comment #15
mglaman