Just installed devel(7.x-1.x dev, 01/16) and devel_themer(7.x-1.x dev, 01/15) modules on drupal 7.x dev, dated 0/19. Only standard modules installed. Installed devel, then devel_themer. See following msg, though don't know affect. Clear cache removes msg momentarily until any page called.
Notice: Undefined index: preprocess functions in devel_themer_theme_twin() (line 512 of /Users/rocks/Sites/dru0119/sites/all/modules/devel_themer/devel_themer.module).
| Comment | File | Size | Author |
|---|---|---|---|
| #16 | debugging-notices.patch | 801 bytes | kenneth.venken |
Comments
Comment #1
JeremyFrench commentedHi there. Thanks for reporting. Couple of questions.
What theme are you using for the front end? Are pages loading ok except for message?
Comment #2
dcrocks commentedI am building my own with bartik as the base. The pages seem to load ok but I've no real content yet. Just tried with bartik as theme and can't reproduce. Will see if I can dig deeper.
Comment #3
aimeee commentedSame error message, just installed / enabled Zen + created / enabled a sub-theme... using Zen 7.x-3.x-dev. All pages are loading fine except for the error message. Any pointers would be great.
Comment #4
JeremyFrench commentedI can stop the error message showing easily enough by checking for the index. But I'm a bit worried it appears at all.
It looks like it is a side effect of sub theming. I'll try and investigate further.
Comment #5
aimeee commented@Jeremy -can you go into more detail about what you did to check for the index? thanks!
I changed:
to:
is that what you mean?
Comment #6
Punchy commentedSame as @ameee : same error message, just installed / enabled Zen + created / enabled a sub-theme... using Zen 7.x-3.x-dev.
Comment #7
cesarpo commentedI've got the same notice, and im not using a base theme., im developing the theme from scratch
Comment #8
marknr commentedI can provide Firebug debugging information about this - It happens reliably on my system, let me know if you would like it, and what you would find most useful.
mnr
Comment #9
localhost commentedThis seems to occur when the theme folder contains extra template files. When I remove my custom node--node-type.tpl.php files and clear the cache, the error does not occur.
Comment #10
RobW commentedLocalhost, by extra template files do you mean in-use-but-custom template overrides in the currently used theme folder, or unused tpls, like for a content type or nid that doesn't exist?
I'm having similar errors but the blog post here has me thinking all it is is that I printed some optional fields without an
check.
Comment #11
liam morlandThis may be related to #1239562: Undefined index errors.
Comment #12
kenneth.venken commentedCould you add this to the devel_themer_theme_registry_alter function:
and post the output here.
Comment #13
dcrocks commentedInstalled a clean copy of drupal 7.7 . Added latest copy of devel and devel_themer and enabled them. No error messages.
Copied and renamed bartik to sites/all/themes/barty, made it a subtheme of bartik, and then enabled it.
Removed trash. Tests were bad
Comment #14
dcrocks commentedJust scratch everything i wrote above except the test installation. Really distracted this morning and made several errors. Will try again.
Comment #15
dcrocks commentedInstalled a clean copy of drupal 7.7 . Added latest copy of devel and devel_themer and enabled them. No error messages.
Copied and renamed bartik to sites/all/themes/barty, made it a subtheme of bartik, and then enabled it. No messages. Made it default, no messages
Of course I don't get error messages any more because of fix in #1239562: Undefined index errors. Where exactly do you want me to put that code and where should I see the results?
When are the files created in /tmp deleted?
Comment #16
kenneth.venken commentedSee attached patch for where you should place the code. This code should print the hooks which don't have any preprocess functions attached to them. (in your html).
Remember to clear you cache.
Comment #17
kenneth.venken commentedOk, i copied all files from bartik to a new theme named barty. Changed the info file and references of bartik in template.php. => no notices
I created an extra template file: page--front.tpl.php, i cleared the cache. => no notices
Comment #18
kenneth.venken commentedComment #19
liam morlandI disabled a custom module and notices went away. Re-enabling that module, I can get rid of the notices by changing my implementation of hook_theme_registry_alter() to add NULL values for 'preprocess functions', 'process functions', and 'theme path'; previously, these properties had not been set. Since the values are now set, there are no more undefined index errors.
Other parts of the theme system check that these values are set before trying to use them. I think Theme developer should do the same, as implemented by my patch in #1239562: Undefined index errors.
Comment #20
kenneth.venken commentedIt seems your right. In theme() they check for the (pre)processor functions too: (line 884)
I'll reopen the other issue and close this one. Could you alter your patch so it uses isset() in stead of empty() so it is consistent with the rest of the code.
Comment #21
kenneth.venken commentedsee #1239562: Undefined index errors for a fix.