Bug in View module, version 6.x-2.8
With the following patch: http://drupal.org/files/issues/655770-build-sort-bad-parens.patch

NOTE: I have seen this error on the forum but none of the solution helped me. I think it's a different bug that give me the same error.

I installed the module SimpleTest than I ran some tests. They all fail with a strangely formatted error, containing HTML code on it:
An error occurred. /batch?id=48&op=do { "status": true, "percentage": 33, "message": "\x3cbr/\x3eProcessed test 1 of 3 - \x3cem\x3eMenu links\x3c/em\x3e.\x3cdiv class=\"simpletest-pass\"\x3eOverall results: 16 passes, 0 fails, and 0 exceptions\x3c/div\x3e\x3cdiv class=\"item-list\"\x3e\x3cul\x3e\x3cli class=\"first last\"\x3e\x3cdiv class=\"simpletest-pass\"\x3eMenu links: 16 passes, 0 fails, and 0 exceptions\x3c/div\x3e\x3c/li\x3e\n\x3c/ul\x3e\x3c/div\x3e" }
Fatal error: Call to a member function get_handlers() on a non-object in [...]/www/sites/all/modules/views/includes/view.inc on line 372

As suggested on the forum, I try to disable the View module (and View UI module) and re-enable it. When I re-enable it, it give me a white page with a single error line on it:
Fatal error: Call to a member function get_handlers() on a non-object in [...]/www/sites/all/modules/views/includes/view.inc on line 372
When I go back to the Web Site, the module is enabled as it should be.

Someone said it can be a problem with the cache so I deactivated it in the menu:
Administer > Site building > Views > Tools > Basic
Check "Disable views data caching"

Now, when I run a test (any test), I get the same error, but from a different View file:
An error occurred. /batch?id=49&op=do { "status": true, "percentage": 100, "message": "\x3cbr/\x3eProcessed test 1 of 1 - \x3cem\x3eBlock functionality\x3c/em\x3e.\x3cdiv class=\"simpletest-pass\"\x3eOverall results: 64 passes, 0 fails, and 0 exceptions\x3c/div\x3e\x3cdiv class=\"item-list\"\x3e\x3cul\x3e\x3cli class=\"first last\"\x3e\x3cdiv class=\"simpletest-pass\"\x3eBlock functionality: 64 passes, 0 fails, and 0 exceptions\x3c/div\x3e\x3c/li\x3e\n\x3c/ul\x3e\x3c/div\x3e" }
Fatal error: Call to a member function override_option() on a non-object in [...]/www/sites/all/modules/views/modules/statistics.views_default.inc on line 22

If I try to disable and re-enable the View module when the cache is disabled, I get the same error as before.
Fatal error: Call to a member function get_handlers() on a non-object in [...]/www/sites/all/modules/views/includes/view.inc on line 372

I tried to apply the following patch but it didn't change anything:
http://drupal.org/files/issues/admin.inc-380560-7_HEAD.patch

Everything else on the Web Site seem to work normally.

Thanks

Comments

gaellafond’s picture

Project: Drupal core » Views (for Drupal 7)
Version: 6.16 » 6.x-2.8
Component: other » Code

I have multiple web site with similar Drupal implementation. I keep them all up2date.

One of the Web Site, the smaller one, didn't have the previous errors so I tried to install SimpleTest on it and it works fine. I will take a snapshot of the buggus Web Site and remove modules, views, theme, etc. until I get ride of that bug. I will post the result latter.

[edit]
I think it's a conflict between
Statistics 6.16 from Core - optional
And
Views, SimpleTest, and maybe something else?

When I deactivate this module (statistics), everything is fine. But, when I reproduce the "Boggus Server" configuration on the "Working Server", with statistics module activated, everything is fine. They both have exactly the same version for all modules.

I'm now investigating the module statistics to see if it's due to some weird configuration, cache, overflow of logging or anything else.

[edit]
After hours of investigation, it's a bug with Access Log feature of Statistics module. I will make a bug report about that.

gaellafond’s picture

Status: Active » Closed (fixed)
teebo’s picture

Hello,

Any advancements on this issue?
I know we shouldn't touch core modules, but could you tell me where you made your modification in the Statistics module to contain the bug?

Thank you.

gaellafond’s picture

Sorry the Bug was closed so I couldn't saw your reply.

I simply deactivate the access log the config on my devel installation, I didn't had to modify any module.

I create an other issue because I couldn't find that one (it was closed, newby error, sorry)
http://drupal.org/node/753700

I explain the bug in detail in there (see my last post). The error is reported to be in view, but I'm pretty sure it's a bug with Statics module. It only occur when View is enabled. I suspect the statistic module to use views when the module is present, to avoid having a dependency on an external module.