Help with a broken empty view

nath - March 11, 2008 - 16:31
Project:Views
Version:5.x-1.6
Component:Miscellaneous
Category:support request
Priority:normal
Assigned:Unassigned
Status:closed
Description

We did something stupid or so but we don't know what it was.The result is that at one of our content types we get the following errors:

* warning: Invalid argument supplied for foreach() in /var/www/drupal.akademie.de/htdocs/sites/all/modules/views/views_query.inc on line 83.
* warning: Invalid argument supplied for foreach() in /var/www/drupal.akademie.de/htdocs/sites/all/modules/views/views_query.inc on line 16.
* warning: Invalid argument supplied for foreach() in /var/www/drupal.akademie.de/htdocs/sites/all/modules/views/views_query.inc on line 197.

If I print_r all views, at this content type I get the following view (in addition to the working ones):

stdClass Object
(
    [build_type] => items
    [type] =>
    [use_pager] =>
    [pager_limit] => 0
    [current_page] => 0
    [offset] => 0
    [used_filters] => Array
        (
        )

)

Has anyone got an idea what went wrong and where to look to fix this? Thanks for any help.

#1

nath - March 12, 2008 - 11:24

using the devel module, I could find out, that the problem is with _views_load_view in the query SELECT v.* FROM view_view v WHERE v.name = 'autor'. The view autor has been deleted, so that explains why there are errors when trying to load that view.

What I do not know though is why that view is being loaded at all.
Can anyone point me in the right direction?

#2

JuliaKM - March 15, 2008 - 02:26

If you haven't already, you should clear the Views cache on your site. You can find the button to "Clear views cache" at:

http://www.mysite.com/admin/build/views/tools

#3

nath - March 17, 2008 - 11:06

I did try that, thanks. It didn't help though.
I now have created a completely empty view that is called "autor". That results in at least the error messages to be gone.

I still have no idea where to look for the real solution though.

#4

merlinofchaos - March 17, 2008 - 16:31

You probably have something loading the code manually. You should do a debug backtrace, figure out exactly where the code is that's loading the view, and then start examining the data.

#5

nath - March 31, 2008 - 11:57
Status:active» fixed

Found it: Some custom pager that everyone had forgotten was using that view. Now, all is fine again. :)

#6

Anonymous (not verified) - April 14, 2008 - 12:05
Status:fixed» closed

Automatically closed -- issue fixed for two weeks with no activity.

 
 

Drupal is a registered trademark of Dries Buytaert.