Problem/Motivation
Warning messages - Panopoly seems OK. Though I had installed the Panopoly News App and this is not showing up as listed as an app (assuming it is an app)
(Issue about this: http://drupal.org/node/1819686)
Perhaps the warnings are something to do with why Panopoly News is not listed as an App.
The warnings are shown at the end of this issue, in the section required by the issue template.
Proposed resolution
Fix so that these warnings don't get displayed.
Remaining tasks
As above.
User interface changes
Not applicable - don't think UI changes are the issue.
API changes
Perhaps it is an issue with using an API incorrectly.
Original report by [username]
Warning: Illegal string offset '#theme' in apps_preprocess_apps_install_page() (line 137 of ..profiles/panopoly/modules/contrib/apps/theme/apps.theme.inc).
Warning: Invalid argument supplied for foreach() in element_children() (line 6300 of ../includes/common.inc).
Warning: Illegal string offset '#children' in drupal_render() (line 5767 of ../includes/common.inc).
Warning: Illegal string offset '#children' in drupal_render() (line 5777 of ../includes/common.inc).
Warning: Illegal string offset '#children' in drupal_render() (line 5815 of ../includes/common.inc).
Warning: Illegal string offset '#printed' in drupal_render() (line 5822 of ../includes/common.inc).
Comment | File | Size | Author |
---|---|---|---|
#9 | apps-fix_illegal_string_offset-1820266-9.patch | 1.3 KB | InternetDevels |
Comments
Comment #1
therobyouknow CreditAttribution: therobyouknow commentedRunning on MAMP PRO on MacOS. PHP 5.4.4, MySQL 5.5.25
Drupal 7.16. Updated to latest using drush.
Although these messages appeared, Panopoly appears to run OK. It is disconcerting to see them though. Not fixing this issue may be storing up problems for later.
Thanks,.
Comment #2
populist CreditAttribution: populist commentedI will look into these, but think they are probably PHP 5.4 issues and glad it isn't causing you too much trouble.
In terms of Panopoly News, it is currently not ready for RC1 (boo) so it isn't there but it shall be soon and then it will appear in the Apps section.
Comment #3
therobyouknow CreditAttribution: therobyouknow commentedThanks @populist for your quick follow up - most appreciated!
Comment #4
populist CreditAttribution: populist commentedI did some more digging here and believe this is an issue with Apps. The problem here is that the logic that defines a #theme callback is doing an isset() check on $featured_apps in apps_preprocess_apps_install_page() to add its callback. However, in the case where there are no featured apps, the $featured_apps variable *IS* set but it contains the string "No applications currently available." instead of information around Featured Apps.
I made a patch which I think resolves the problem mentioned in #1, but I don't use the featured apps section so not sure. However, this should fix the error so wanted to throw this out.
Comment #5
therobyouknow CreditAttribution: therobyouknow commentedThanks @populist for the further follow up. I noticed that you changed the title of the issue to be more precise about the problem - thanks.
Comment #6
febbraro CreditAttribution: febbraro commented@populist I think you forgot to attach the patch.
Comment #7
therobyouknow CreditAttribution: therobyouknow commentedJust out of interest, how do you "dig", @populist - do you use a debugger to find problems like these?
I'm currently evaluating the following PHP debuggers, welcome a quick vote from you as to which you use, if any, or something else?
Anything with xdebug pre-compiled would be a bonus (or even better, doesn't rely upon it), it seems to be a pain to setup, having to compile it, find dependencies, etc.
Comment #8
populist CreditAttribution: populist commented#7 - I did not use a debugger, but just saw some error reports from Panopoly so I figured the code manually.
#5 - I apologize for not attaching the patch and it is now gone. Apps might need a larger PHP 5.4 review.
Comment #9
InternetDevels CreditAttribution: InternetDevels commentedI have created the patch, which is supposed to fix the issue for 7.x-1.0-beta7 version of the module.Yet, it seems the output was changed in the last release of dev version of the module, thus it's not working for this version at the moment (not displaying featured app, ratings etc). That's why I don't understand the idea of the plans concerning Apps Install page. The logic of this patch is irrelevant for 7.x-1.x-dev version.
Comment #10
hefox CreditAttribution: hefox commentedNeeds work based on this being a patch against beta
Comment #11
hefox CreditAttribution: hefox commented