After disabling Workbench, the error message "Notice: Undefined offset: 1 in views_block_view()" displayed on all site pages. On doing a debug_backtrace(), this seems to be being caused by the block "View: workbench_edited" not being removed from the enabled block from the region list cache (?) when the the module was disabled, though the other two View block displays generated by Workbench did not cause an error.
[7] => Array
(
[file] => /Users/path/to/sites/modules/block/block.module
[line] => 658
[function] => _block_render_blocks
[args] => Array
(
[0] => Array
(
[views_workbench_edited-block_1] => stdClass Object
(
[bid] => 45
[module] => views
[delta] => workbench_edited-block_1
[theme] => bartik
[status] => 1
[weight] => -12
[region] => footer
[custom] => 0
[visibility] => 0
[pages] =>
[title] =>
[cache] => -1
)
Clearing caches did not fix this.
To remove the error I enabled Workbench, went to the blocks admin page, and as expected the blocks were right back in the region were I had placed them. Setting the Workbench block region assignments '-None-', saving, and then disabling Workbench effectively took care of the error.
Not sure why a View block being generated by a disabled module was still being called, esp. after caches had been cleared (I am swamped and haven't had a chance to study the module code), just putting this out in case anyone else runs into this issue.
Comments
Comment #1
stevectorHad you overridden this View? If so, it'd be living in the database even after workbench was disabled. But then I'm not sure why it wouldn't be available to the block system.
Are you able to reproduce this error consistently? I have not reproduced it.
Comment #2
davmorr commentedI had not overridden that View. We are still in pre-pre-production and I just had to remove the workflow processing from the the mix without losing the configurations that were set up during during a testing and evaluation phase. I have switched the module on and off, as needed during dev, and haven't run into any other issues, but I don't think that I have used that block recently. If I have a chance over the weekend I will try to recreate the scenario and will report back if I have any "luck." Cheers!
Comment #3
stevectorReopen if you run into this again.