After upgrading the Commerce Kickstart module, I cannot get the update script to complete.
I see this error in the log:
max() [function.max]: Array must contain at least one element in taxonomy_pathauto_bulk_update_batch_process() (line 195 of /profiles/commerce_kickstart/modules/contrib/pathauto/pathauto.pathauto.inc).
Please let me know what other information I can provide.
It is failing to finish Commerce Kickstart module update #7205
I believe this line of code in commerce_kickstart.install is causing this:
taxonomy_pathauto_bulk_update_batch_process($sandbox['pathauto']);
I have the PathAuto module installed, enabled, with default configuration. I have only about 2-3 taxonomy terms listed.
| Comment | File | Size | Author |
|---|---|---|---|
| #11 | 1872224-11-module_exists.patch | 895 bytes | nils.destoop |
| #3 | 1872224-ignore-pathauto.patch | 823 bytes | bojanz |
Comments
Comment #0.0
rleem12 commentedupdated to include 7205
Comment #0.1
rleem12 commentedadded more information
Comment #1
bojanz commentedComment #2
rleem12 commentedThis error is repeated in the logs for many pages when the update script is run
max() [function.max]: Array must contain at least one element in taxonomy_pathauto_bulk_update_batch_process() (line 195 of /profiles/commerce_kickstart/modules/contrib/pathauto/pathauto.pathauto.inc).
As if it were running an infinite loop.
This action actually took down every website on my server as it was overloaded by PHP activity
Comment #3
bojanz commentedWell, this sucks :/
Looks like the update code in Pathauto is to blame: #1805486: Bulk updating taxonomy terms does not work at all.
And it looks like it doesn't have code to handle the case where no terms were returned from the query.
Here's a quickfix, it will disable the pathauto update code and allow you to complete updating Kickstart.
In the meantime, we'll need to figure out how to proceed here (patch pathauto probably)...
Comment #4
rleem12 commentedThank you for the patch. It did allow me to proceed further with the update process. I am now getting the following error:
An AJAX HTTP error occurred. HTTP Result Code: 200 Debugging information follows. Path: http://www..com/update.php?op=selection&token=CIFV-RJwEp6LpUpHYqVvKSIGf8... StatusText: OK ResponseText: Fatal error: Call to undefined function title_field_replacement_info() in /profiles/commerce_kickstart/modules/commerce_kickstart/commerce_kickstart_product_ui/commerce_kickstart_product_ui.module on line 193
Comment #5
bojanz commentedWhat is the kickstart version you are updating from?
It should not be possible for the Title module to be missing.
Comment #6
rleem12 commentedLooking at the zip files on my hard drive it looks like I have installed:
7.x-1.8-core
7.x-1.10
7.x-2.0-rc1-core
7.x-2.0-rc4-core
7.x-2.0-core
After this last round, my store is completely down. Anything you can tell me to assist me getting stable again, as quickly as possible? Thanks in advance!
Comment #7
rleem12 commentedI moved a copy of the Title module into the profiles/commerce_kickstart/modules folder allowing the updates to all complete successfully.
I am trying to access the front page and receive this error:
Fatal error: Call to undefined function libraries_get_path() in /profiles/commerce_kickstart/modules/commerce_kickstart/commerce_kickstart_product_ui/commerce_kickstart_product_ui.module on line 105
Comment #8
bojanz commentedIf Title was not in profiles/commerce_kickstart/modules/contrib then you have not properly uploaded Kickstart 2.0
Same thing for Libraries.
Comment #9
rleem12 commentedDoes this update do any moving around of files or folders? The reason that I ask is that I have reloaded my store from a backup. The title and libraries modules are in tact in the contrib folder in my pre-updated version.
I also do not think it is likely that I would copy up the files and omit 2 folders, but all of the rest are there.
Comment #10
bojanz commentedNo, those two modules have always been under profiles/commerce_kickstart/modules/contrib, which is what's making me think your installation is damaged in some way.
Comment #11
nils.destoop commentedI have the same error in 7.x-2.4, but it's because the title module is disabled.
Title only has 'Commerce Kickstart Lite Product' as dependency. So if product UI also has a dependency on it, it should be added in the dependency list.
If not (i think this is the case, as it's only on field_create_instance), a module_exists check should be added.
Comment #12
jsacksick commented@zuuperman: Your fix has been commited to dev but why did you remove the title module ?
Comment #13
xaxcontinued from http://drupal.org/node/1932902
Thanks.. I did that (change the path auto lines), all 8 updates now ran successfully until reaching 100%, after which I got the
Update #7205
Important: We couldn't add the new fields to the index.
message again.
When running update.php it now says no new updates.. On the site still no products to be seen (I know they are there, I can get the individual ones in view through admin). I did bulk update the aliases through admin, made lots of changes but no product overview pages are generated..
(I also disabled the two old product Views, and checked, Title and Libraries modules are installed and enabled and in the contrib folder)
Any way I can add the #7205 fields to the index myself? How and where?
Comment #14
jsacksick commentedReverting your search api index should fix the issue...
Go to admin/config/search/search_api/index/product_display/, you should be able to revert your index, then reindex everything and it should work !
Comment #15
xaxSorry to bother you again, and again thanks for all the help. Feel We'll get there in the end..
Have wiped and reindexed. As a result I have now lost all menu buttons that referred to the various product types (which used to be organised through 'collections'). So how do I now create new overviews per category?
The old path to a product used to be xxxx.com/collection/seasonal/product1, if I now type xxxx.com/seasonal/product1 I do get the single product in view, but with an error:
Notice: Undefined index: summary in node_tokens() (line 142 of /services5/webpages/w/h/xxxxx.com/public/modules/node/node.tokens.inc).
I have no clue how to get the page back that showed all products of one type (e.g. the seasonal ones) on one page?
Comment #16
jsacksick commentedWhich menu buttons are you talking about ? The ones that are referring to the collection ? These are not pointing to the taxonomy/term view anymore, we're instead using a view based on the product display index.
Perhaps you need to rebuild the taxonomy menu by going to the taxonomy vocabulary edition page (admin/structure/taxonomy/collection/edit).
Can you check if your collection products view is there ? (admin/structure/views/view/collection_products/edit)
Comment #17
nils.destoop commented@jsacksick The title module was not needed, because the title that needs to be shown can come from multiple fields. We have custom DS field that shows the correct title.
Comment #18
xax@ #16.. jsacksick.. once more thanks for your help and suggestions! I have looked at the whole issue, the views, the database, tried to make it work but failed. So I decided to have a completely clean install of commerce kickstart 2.4 (drupal 7.20) on another site I have on the same hosting provider. Guess what I found: the search API gives me the following error:
What this boils down to: my user has all permissions on my database except for one: creating temporary tables, so search API and facets do not work (so 'all products' button gives the same error too. This means I can't run kickstart on the provider anymore, as apparently now the whole product thing is run using facets.. So the error is with my terrible host, not kickstart.
For those in the UK: do not host your kickstart on talktalkbusiness, as they refuse to grant this 'create temporary tables' permission! and that at a price which should include a red carpet + rolls royce + driver.
Anyway, what I need to know now (until I move host in the near future).. what is the last Kickstart 2.x that uses taxonomy and view to display the products (rather than search api and views)?
And, can I switch back by replacing the 2.4 files with the older version and then run update.php? (2.4 never updated the product tables in my database), or do I need a full clean install and then rebuild the site?
(or perhaps I can manually re-instate the taxonomy view of products?)
Regards,
Xander
Comment #19
jsacksick commentedThe last Kickstart release that uses a Taxonomy view is the rc2, but it contains an old and unsecure version of the Drupal core and of course you will loose other bugfixes and improvements....
Comment #20
jsacksick commentedComment #20.0
jsacksick commentedtypo, removed extraneous information