Closed (fixed)
Project:
Chaos Tool Suite (ctools)
Version:
7.x-1.0
Component:
Code
Priority:
Normal
Category:
Bug report
Assigned:
Unassigned
Reporter:
Created:
3 Oct 2011 at 20:05 UTC
Updated:
22 Jun 2012 at 16:42 UTC
Jump to comment: Most recent file
Comments
Comment #1
floleft commentedTo remove the error for now, I added an isset() check for the variable inside the if($test). There may be a bigger issue though.
Comment #2
chriscalip commentedI encountered the same problem with the situation of having installed panels then disabled panels; without removing the unnecessary module : page_manager from ctools.
Disabling page_manager solves the problems.
I think this solves this issue. Please turn it back to active if this is not the case.
Comment #3
chriscalip commentedComment #5
jbateau commentedThe code has a bug. Reinstalling page_manager just causes the bug not to be hit.
old code:
should be:
Comment #6
merlinofchaos commentedInteresting.
Yes there is a minor bug here. What's more interesting is that the minor bug may have revealed a bug with a task handler somewhere. When you run into this bug, do you know what the $plugin that's being checked is?
Comment #7
jbateau commentedwell, I forgot about that. But the issue is that the code is simply wrong: the $test variable does not exist elsewhere in the function and therefore the code relies on it getting automatically initialized with false.
Which is Bad Practice and will cause this type of issue.
Comment #8
lisa.rae commentedThis appeared for me when I had the Panels module activated, and subsequently deactivated it. Activating Panels again caused the notice to go away.
Comment #9
wxman commentedI was getting this using the 7.x-1.x-dev. The fix in #5 made it go away for me.
Comment #10
chrylarson commentedI had the same situation as #8 and #5 fixed it for me as well.
Comment #11
jramby commentedI created a patch from #5. Wish it really fix the problem :)
Comment #12
merlinofchaos commentedComment #13
tim.plunkettThis makes the else statement match the above if statement, looks good to me.
Committed http://drupalcode.org/project/ctools.git/commit/06e628c.
@jramby, you should set up your git information. You got credit on that commit (see http://drupal.org/user/603140), but it looks weird on the commit page.
Comment #15
quinn.mckinsey commentedAlright, taking merilinofchaos's advice I'll post my problem here, even though I'm having this issue with 7.x-1.0 and not 7.x-1.x-dev.
Here is the situation:
I have updated drupal core from 7.12 to 7.14. I disabled all modules before upgrading, which seems to have gone well. Now I'm trying to turn the modules back on. Enabling ctools and page manager gives the error. However, the solution given on #5 does not apply as the code in context-task-handler.inc on line 70 is already corrected.
Also, turning page manager off and back on does not fix the problem. Warnings do disappear when page manager is turned off.
Comment #16
quinn.mckinsey commentedComment #17
quinn.mckinsey commentedFurther update:
Enabling Panels causes the error to disappear and disabling Panels causes the error to return. Maybe, this has to do with an error on Panels part.
Hope this helps.
Comment #18
swentel commentedLooks like the patch that committed introduced a new notice, patch over at #1566098: PHP notice: Undefined variable 'test' in ctools_context_handler_get_render_handler()
Comment #19
digibrill commentedPatch in #11 seemed to work for me.