When changing the taxonomies' machine names in CK this notice pops up:

Notice: Trying to get property of non-object in commerce_kickstart_taxonomy_preprocess_views_view() (line 41 of.... commerce_kickstart/modules/commerce_kickstart/commerce_kickstart_taxonomy/commerce_kickstart_taxonomy.module).

It 's not really a bug is it? But a lot of people run into it (try googling it and you will find a lot of CK sites stuck on this). Disabling commerce_kickstart_taxonomy is the easiest way to get rid of it, but then one of course looses the build in Product Catalog.

Perhaps a warning not to change the machine names? Is there a way to properly change them? Rebuild the search index with the new names didn't do it for me, but perhaps I didn't do that properly.


vasike’s picture

Category: bug » support

i think this a Drupal core issue/bug: it should have the same approach an Content types have: a way to lock the machine names.

There are 2 issues with patches, one for Drupal core and one for Features (as they are built here).
- #2070097-1: Add extra properties Taxonomy vocabularies same as for Content types
- #2070123-1: Lock taxonomy vocabularies same as Content type

So actually you shouldn't change the machine and shouldn't be able to do it.

vasike’s picture

Status: Active » Needs review

as Drupal core and Features issues that should provide solutions are on "needs review", i put this on the same Status
so maybe someone will help with the solutions progress

jackdaniel9’s picture

We have this error, do you have any solution ?

Notice: Undefined index: 0 in commerce_kickstart_taxonomy_preprocess_views_view() (line 39 of /profiles/commerce_kickstart/modules/commerce_kickstart/commerce_kickstart_taxonomy/commerce_kickstart_taxonomy.module).

Notice: Trying to get property of non-object in commerce_kickstart_taxonomy_preprocess_views_view() (line 41 of /profiles/commerce_kickstart/modules/commerce_kickstart/commerce_kickstart_taxonomy/commerce_kickstart_taxonomy.module).

jsacksick’s picture

@jackdaniel9 : This probably means you updated the view with the machine name collection_products and you removed the argument needed by the view (The Taxonomy term id).

jackdaniel9’s picture

If someone with the same error :

We have 2 Kickstart Website

For the first website, we update the version of Kickstart to 7x2.10, the error occurred. (Website with No taxonomy category)

The machine name of Collection Products (Product display) was 'page' and we change for 'collection_products' the error is gone.

For the second Website, the version of Kickstart is 7x2.9, no error occured, and the machine name of Collection Products is 'page'. (Website with taxonomy category)


smurfxx’s picture

Issue summary: View changes

I write my experience with the view "Collection products"
1. In the view details, where you can edit that view, the path of the page is "/product_category" but the menu url (the black on the left of the default site) points to "/product-category", is that right?
2. If I click on the menu I don't have warnings or errors but I can see only products of that category, if I go to "/product_category" I can see any product of that category, even sub-categories products (perfect for what I want to do) but I receive the error you told before.

Also, in the demo site of commerce kickstart we can see a nice banner for every category (To Carry, To Drink With, To Geek Out...), how can I do the same???

This view, for me is the most important of the site, but it's really a mystery...

mglaman’s picture

Status: Needs review » Closed (works as designed)

If you're using Commerce Kickstart the provided catalog is expecting specific things, changing the vocabularies and expecting the default views/search indexes to work will cause unexpected issues.