I get this error when I try to revert views that have been exported to a feature. This is causing a serious problem for us as we cannot revert out views to our production system.
My views are in my feature. However when I revert, I get the fatal error. When I do a drush cc all - the error disappears and the view is in list of views. If I do another drush cc all (nothing else) the views disappear from the list (database)
Attached sequence, screen shots and feature.
Screen shot 1 shows the views are not in the list
$ drush fr simplybiz_job_spheres
Do you really want to revert views_view? (y/n): y
Fatal error: Call to a member function delete() on a non-object in /var/aegir/platforms/bc77_stage_20110901/sites/all/modules/contrib/views/views.module on line 1463
Drush command terminated abnormally due to an unrecoverable error. [error]
Error: Call to a member function delete() on a non-object in /var/aegir/platforms/bc77_stage_20110901/sites/all/modules/contrib/views/views.module, line 1463
$ drush cc all
'all' cache was cleared [success]
$ drush fr simplybiz_job_spheres
Do you really want to revert context? (y/n): y
Reverted context. [ok]
Notice above that I'm not asked if I want to revert the views. Screen shot 2 shows the views are now in the list
$ drush cc all
'all' cache was cleared
Screen shot 3 shows the views have disappeared again
Also logged at Panel issue #1264826
| Comment | File | Size | Author |
|---|---|---|---|
| simplybiz_job_spheres-7.x-1.0-dev.tar_.gz | 6.67 KB | diricia | |
| Screen shot 2011-09-23 at 11.10.15 AM.png | 34.14 KB | diricia | |
| Screen shot 2011-09-23 at 11.09.32 AM.png | 55.5 KB | diricia | |
| Screen shot 2011-09-23 at 11.06.41 AM.png | 43.38 KB | diricia |
Comments
Comment #0.0
diricia commentedAdded a line break
Comment #1
dawehnerIt would be definitive kind of cool, if you could try several things.
* update to recent versions of ctools/features/views
* See whether it's still happening in general
* Reexport the view you have there
* Provide a really simple feature to reproduce the problem. Sadly this one isn't valid utf8 so it's not possible to open the file.
This error happens if the view object couldn't be initialized and then really something big is broken.
Perhaps it should be considered to move this issue to features as well.
Comment #2
mrfelton commentedSounds like the problem in #1264826: revert views calls views delete() & throws a fatal error which was resolved by upgrading Views to the latest -dev code.
Comment #3
dawehnerThanks for finding the duplicate!.
Comment #5
tim.plunkettComment #5.0
tim.plunkettAdded explanation