Hi all ! I'm very new in Drupal and it's my first post (and first website too).

Apologies if anything is unproperly explained.
I read a lot of "how to" before submitting this issue.
I hope I'm allowed to submit here as it seems nothing looks like my issue elsewhere.
I get error :

  • Notice: Undefined index: taxonomy_term in taxonomy_field_formatter_view() (line 1610 of C:\wamp\www\drupal\modules\taxonomy\taxonomy.module).
  • Notice: Trying to get property of non-object in taxonomy_field_formatter_view() (line 1610 of C:\wamp\www\drupal\modules\taxonomy\taxonomy.module).

I found errors looking like mine in there but that issue refers to module Taxonomy Formatter 7.x-1.x-dev that I do not use. I don't have that module....confusing !

Here is what happen :
Easy to repeat.
Drupal version 7.21 , Display Suite.

Steps to repeat :
For a content named "property" I create a custom display named "full content" with Display Suite 7.x-2.2
I don't use default or teaser display.
For my custom display I select a layout Fluid three column stacked then have 5 regions: header, left,middle, right, footer.
Create a custom block field named "block property entete", populated with a View block.
In that View block I add a taxonomy field field_type_bien associated to vocabulary type_bien.
I set display for that Tag fiel to brut but if link it's same.
I put my field "block property entete" in region header.
I put another field, say "image" in my region left.

Then when I display the content page the error pops up.

If I display also the tag field field_type_bien in another region, like under my image, I don't have that error.

But I don't want to directly display my tag fields in regions.
I want them to be displayed using Views wrapped in custom block fields.

I need to add a lot of taxo fields in several region of my layout, and rewrite, set some to hidden, and rewrite display of others using Token.
Looking for display sentences like this : "villa" for "rent" "monthly" in "paris", where villa, rent, monthly, and paris are taxonomy fields.
So "rent", "monthly" and "paris" are hidden, but "villa" is set to brut, and rewritten using Tokens made available by reordering prior to "villa" in field list of my View.

When I try using List text fields it works but I need Taxo fields...

I must add that I use the same way in my home page.
I create a page using Views linked to home to replace my "main content" home region.
In this case I don't use Display Suite.
My view is named "newest listing" and displays in a grid photos with taxonomy field rewritten the same way, so that I have something like "Apartement" for "sale" in "paris" using 3 taxo field making a sentence.
Error occured there too untill I delete and recreate all the same way.
It looks okay now after my Views update.

Work on that since 4 days, delete all my taxonomies and recreate. Also delete all my Views and recreate. I just update to Views 7.x-3.7 today but still same.
I read dozens of issues but none seems to fit mine ???
I don't know if it's a Taxonomy, Views, or Display Suite problem...

Comments

fransoa’s picture

Component: Miscellaneous » taxonomy data
Category: bug » support
Priority: Major » Normal

May be it's not a bug.
May be I miss something...
Anyway I'm still asking for support, if anyone has a clue for solution ?

Mołot’s picture

Can you recreate this bug on clean Drupal7 + Views? Or you need Display Suite for it to happen?
If you can without Display Suite, post a way to recreate it. If it appears only when you use Display Suite, move this request there.

fransoa’s picture

I can't. So it's move to Display Suite. Thanks

Mołot’s picture

Project: Views (for Drupal 7) » Display Suite
Version: 7.x-3.7 » 7.x-2.2
Component: taxonomy data » Code
fransoa’s picture

Thanks Molot, I was rewriting and testing again everything to make it more clear.
It's slightly different now. Needs Views 7.x-3.7

Steps to repeat :
For a content named "property" I create a custom display named "full content" with DS.
I don't use default or teaser display.
For my custom display I select a layout Fluid three column stacked then have 5 regions: header, left, middle, right, footer.
Create a custom block field named "block property entete", filled with a View block.
In that View block I add a taxonomy field field_type_bien associated to vocabulary type_bien.
I add a contextual filter on content node id with when value filter is not available, give a default value 'content ID from URL'so that my block refers to his content "property".
I put my field "block property entete" in region header.
I put another field, say "image" in my region left.

Then when I display the content page the error pops up.

Notice: Undefined index: taxonomy_term in taxonomy_field_formatter_view() (line 1596 of C:\wamp\www\drupal\modules\taxonomy\taxonomy.module).
EntityMalformedException: Missing bundle property on entity of type taxonomy_term. in entity_extract_ids() (line 7633 of C:\wamp\www\drupal\includes\common.inc).

I also have a display under the red flag saying :
Error
The website encounters an unexpected error. Try again later (translate from french).

And my admin menubar disappear. I must Backspace on keyboard to get access to admin.
I add that in the admin>structure>views of my "block property entete", the preview is okay.

If I display also the tag field field_type_bien in another region, like under my image, I don't have that error.

I don't want to directly display my tag fields in regions.
I want them to be displayed using Views wrapped in custom block fields.

I need to add a lot of taxo fields in several region of my layout, and rewrite, set some to hidden, and rewrite display of others using Token.
Looking for display sentences like this : "villa" for "rent" "monthly" in "paris", where villa, rent, monthly, and paris are taxonomy fields.
So "rent", "monthly" and "paris" are hidden, but "villa" is set to brut, and rewritten using Tokens made available by reordering prior to "villa" in field list of my View.

When I try using List text fields it works but I need Taxo fields...

I must add that I use the same way in my home page.
I create a page using Views linked to home to replace my "main content" home region.
In this case I don't use Display Suite.
My view is named "newest listing" and displays in a grid photos with taxonomy field rewritten the same way, so that I have something like "Apartement" for "sale" in "paris" using 3 taxo field making a sentence.
So it works without using DS.

Any help really welcome..

commanderflash’s picture

I am having the same issue. I am using display suite to format an ubercart product page. It was working fine and then I tried to use DS to format the teaser. Upon doing so, I receive the same errors noted above when viewing the node. I had to make the format back to the system default instead of using DS for both the default view and the teaser view to make the problem go away. I am using Drupal 7.22, Views 3.7 and DS 2.2.

Due to time constraints, I had to revert to formatting the node with custom templates.

Bob123’s picture

Same error message, after clicking the "Preview" button, while editing a standard node...
Seems to be a Drupal "core" problem, I have no display suite installed, and this message apears while editing a standard node. Even Views seems not to be involved.
Clicking the "Save" button, (without preview) did not shows this message.

Drupal 7.22
Views 7.x-3.7
No Display Suite installed!
Wysiwyg 7.x-2.2
TCPDF (library) 6.0.018

Joefry’s picture

Same error. For me, only when formatting the taxonomy term as plain text; other formats - no error. The view is one of four related views blocks employed together on a page using Display Suite.

aspilicious’s picture

Status: Active » Postponed (maintainer needs more info)

Is this related to display suite? Can anyone verify this bug also exists when they disabled ds?

agileadam’s picture

This may be related, though the patch applies to Drupal Core 7.22: #2128265: Term field not displayed + Notice: Undefined index: taxonomy_term in taxonomy_field_formatter_view() (line 1596 of taxonomy.module)
aspilicious, I disabled DS and still got the error.

aspilicious’s picture

Status: Postponed (maintainer needs more info) » Closed (cannot reproduce)

If you disable DS and it is still an issue this has clearly nothing to do with Display Suite :)

jamix’s picture

stevieb’s picture

Just to confirm Jamix's patch in #12 works -- Thanks