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.
Just upgraded to 7.x-3.4 and have everything stabalized, updated, caches cleared etc. The add to cart, checkout, and empty cart features are all working but when I try to add a product that is already in the cart OR change the quantity and then click 'update cart', I receive an HTTP 500 Error, Internal Server Error. Same thing happens when I click the 'remove' button. I've disabled all other modules on the /cart page and don't know where to go from here. Any suggestions in how I might troubleshoot it are also welcome.
Comment | File | Size | Author |
---|---|---|---|
#11 | rules-errors.txt | 379.77 KB | seagle |
Comments
Comment #1
DanZ CreditAttribution: DanZ commentedThat sounds like something went wrong with your install. You might have a corrupted database. Did you remember to run update.php?
Try downloading a fresh copy of Ubercart, deleting all of the files in sites/all/modules/ubercart, and replacing them.
If that doesn't work, try restoring from the backup you made just before the 3.4 upgrade, and running the upgrade again.
If that doesn't work, try enabling error messages and installing/enabling the Devel module's Krumo error messages. Hopefully, this will help pinpoint the trouble.
Comment #2
TR CreditAttribution: TR commentedPlease search this site for how to figure out what's causing the 500 error. There are hundreds of threads about this. It's highly unlikely that it is caused by Ubercart.
Comment #3
longwaveWe need to know what the actual PHP error message is to be able to help further.
Comment #4
seagle CreditAttribution: seagle commentedYes, thanks for all the quick responses, with error messaging on I'm receiving the following -
Fatal error: Call to undefined function entity_load_single() in /mnt/www/html/microstraindev/docroot/sites/all/modules/ubercart/uc_product/uc_product.module on line 1115 -
if (!empty($result['uc_cart_item'])) {
$item_entity = entity_load_single('uc_cart_item', current(array_keys($result['uc_cart_item']))); //line 1115
if ($item_entity->qty != $qty) {
$item_entity->qty = $qty;
entity_save('uc_cart_item', $item_entity);
}
}
Comment #5
DanZ CreditAttribution: DanZ commentedThis means that the Entity module is not available, possibly because it's not being properly loaded. Check that module. (There may be some other reason that it's not loaded.)
Comment #6
longwaveWhat version of Entity module do you have installed? If you are not using 7.x-1.0, try upgrading.
Comment #7
seagle CreditAttribution: seagle commentedYes, upgrading the Entity module fixed things - from 7.x-1.0-beta8 to entity 7.x-1.0
Thank you all!
Comment #8
seagle CreditAttribution: seagle commentedClosing.
Comment #9
TR CreditAttribution: TR commentedComment #10
seagle CreditAttribution: seagle commentedAn append - its now showing the following error even with a Rules module upgrade
Warning: Illegal offset type in isset or empty in /mnt/www/html/sitename/docroot/sites/all/modules/rules/includes/rules.core.inc on line 1090
Warning: Illegal offset type in isset or empty in /mnt/www/html/sitename/docroot/sites/all/modules/rules/includes/rules.core.inc on line 1126
Comment #11
seagle CreditAttribution: seagle commentedNeed to reopen this - attached are the Devel errors being generated. If I can't make sense of these I'll have to revert to my old Ubercart install.
Just a recap:
Comment #12
DanZ CreditAttribution: DanZ commentedDid you run update.php after you upgraded Rules and Views?
Are all your modules fully upgraded?
Comment #13
seagle CreditAttribution: seagle commentedI did run update, and all modules are not completely up to date. I guess the next thing I can try is to install modules in a different order, updating the views, rules, and entity modules before I run the ubercart upgrade.
Comment #14
longwaveIs this still an issue? The errors in #11 are all Rules related, but it sounds like you either don't have all your modules fully up to date or you have/had incompatible versions installed. If you are still getting these errors with all the latest versions and update.php reporting no updates are outstanding, let us know.
Comment #15
seagle CreditAttribution: seagle commentedI reverted to old code and then retried updates to rules & entity modules with update.php, all is working well. It certainly is strange how the second or third attempt at module updates often resolve this kind of issue.
Thanks for following up.
Comment #16
DanZ CreditAttribution: DanZ commented