On the most recent update of Hex (the dev and 6.x-1.5-beta2), using the Canvas subtheme and enabling the context module results in a WSOD and the following error message in my http error log:

PHP Fatal error: Call to undefined function context_get_plugin() in /sites/all/themes/hexagon/HexagonBase/plug-ins/module_compatibility/context/context_module.plug.inc on line 19

Steps to reproduce:
1. Fresh Drupal 6.17 install
2. Install Hexagon and Context
3. Make Canvas the default theme
4. Enable Context

I first noticed an issue when I updated Hex to 6.x-1.5-beta2 and my subtheme's regionfx plugins no longer worked, not sure if this is related. If you need any further information please let me know.

CommentFileSizeAuthor
#5 hexagon-824498.patch1.35 KBdvessel

Comments

bonobo’s picture

@penguininja: this worked with beta1, correct? The functionality broke on the upgrade from beta1 to beta2?

dvessel’s picture

Which version of Context? I had the latest 3.0 beta 5 installed when I made the plug-in. Not enough checks for prior versions I guess.

dvessel’s picture

Never mind, I recreated the bug with the version I have. I'll get a fix up.

bonobo’s picture

We had 3.0 beta 5 as well.

And there's no real need to check for earlier versions. Given that this code is coming out nearly a month after the Context 3.0 beta 5 release date, anyone using this should be up to date.

dvessel’s picture

Status: Active » Fixed
StatusFileSize
new1.35 KB

I was trying to think of a better solution but this will work for the time being. When modules are enable or disabled, the theme registry isn't always cleared. If it was consistently cleared, this wouldn't be a problem and there's no direct way of checking for the changed state. I'm hesitant of keeping track of which modules are enabled in the theme also.

What it does now is just check in the preprocess function if the module is enabled. It works but the preprocess function will always run when it might not be necessary. There are no real practical side effects to this, more of an annoyance.

Commited the patch.

dvessel’s picture

Title: Canvas sub-theme conflict with Context module » Context module compatibility plug-in causes WSOD

renaming

bonobo’s picture

Cool!

We'll test this later today.

penguininja’s picture

Tested with Context 3.0 beta 5 and Hex 6.x-1.5-beta2 and no more WSOD on either Hexagon or Canvas. Thanks!

I'm still experiencing the regionfx issue, but only on pages that are using context_layouts, so I think this is unrelated. I'll open a separate ticket for this issue.

Status: Fixed » Closed (fixed)

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