The taxonomy views integrator module uses the views api wrong, which causes a major problem: #1330716: Views substitutions broken after db_safe() update
As the other people in the issue didn't created an issue here is one.

In general the problem is that you don't call view::pre_execute, which causes this problems but maybe leads to other bugs as well.
The solution is to just drop the manual calling of $view->build(). You know $view->preview does already everything for you.

CommentFileSizeAuthor
#1 1339390-no-pre_execute.patch758 bytesdawehner
Support from Acquia helps fund testing for Drupal Acquia logo

Comments

dawehner’s picture

Priority: Normal » Critical
Status: Active » Needs review
FileSize
758 bytes

pre_execute uses views_set_current_views(), which is an api of views which is required.

Here is a small patch. Considering this as CRITICAL

Sansui’s picture

Status: Needs review » Reviewed & tested by the community

I was reviewing the code for the TVI module after posting this thread - http://drupal.org/node/1410558 - in which my flag relationships were lost while using TVI.

I came to same conclusion the problem was in rendering the view, but did not realize myself that the issue was $view->build(). Thanks for pointing this out! Have tested changes in patch and fixed issue immediately. Please consider reviewed

DuaelFr’s picture

Status: Reviewed & tested by the community » Closed (fixed)

This code seems to have already been integrated.