Hello, I upgraded from 1.1 to 2.x-dev because of the rules support that seems pretty nice.
I just had these warnings and they were gone after I flushed the cache but they are back.
warning: Illegal offset type in /srv/d_lce/www/***/htdocs/includes/form.inc on line 1373.
warning: Illegal offset type in /srv/d_lce/www/***/htdocs/sites/all/modules/rules/rules/rules.module on line 196.
warning: Illegal offset type in isset or empty in /srv/d_lce/www/***/htdocs/sites/all/modules/rules/rules/rules.module on line 80.
warning: Illegal offset type in /srv/d_lce/www/***/htdocs/sites/all/modules/rules/rules/rules.module on line 197.
warning: Illegal offset type in /srv/d_lce/www/***/htdocs/sites/all/modules/rules/rules/rules.module on line 200.
Sometimes, only the first warning shows.
I use Drupal 6.16 (php 5.2.3) and Rules 6.x-1.2.
Also, my /admin/rules/trigger now throws an error :
Fatal error: Unsupported operand types in /srv/d_lce/www***/htdocs/sites/all/modules/rules/rules/rules.module on line 348
Thank you for this very nice module.
| Comment | File | Size | Author |
|---|---|---|---|
| #9 | rules_unique_defaults.patch | 983 bytes | berdir |
| #2 | WebKit.png | 198.52 KB | ethnovode |
Comments
Comment #1
berdir- Do the above errors happen all the time or just on specific pages/actions (if the latter, which)?
- Do you have any rules configured/enabled?
- What is displayed when you enable debug the rules settings
- Which rules version are you using? Maybe updating to the latest version might help
Comment #2
ethnovode commentedThank you for you quick answer.
- The warnings don't show all the time for a page. For exemple, I saw it on /admin/build/modules /admin/build/themes /admin/build/contact , on some page of the site using views. The fatal error only occurs on /admin/rules/trigger and is always there.
- I have rules configured and enabled for : After saving new content ; Workflow state has changed ; Content is going to be saved ; User is going to view a page ; A node has been flagged ; After updating existing content ; User account details have been updated.
- When I enable debug :
- I use the last stable 6.x-1.2 from 2010-Mar-26
Comment #3
berdirOk, thanks, I need to test, I assume I'm using an outdated version myself.
Anyway, one last question for now, can you confirm that those erors only show up when privatemsg_rules is enabled?
Comment #4
ethnovode commentedYes I don't see those warnings when privatemsg_rules is disabled. And the fatal error goes away too.
Comment #5
berdirI'm using rules 1.2 too and I can't reproduce this. Maybe it's a conflict with another module that provides something with the same name.
Can you provide a list of your enabled modules, especially those that have rules integration?
You can also try to disable them one by one until privatemsg_rules works on admin/rules/trigger. The last-disabled module will be the one that is causing this and then we can start to figure out what to do to have them working together.
Comment #6
berdirComment #7
ethnovode commentedI think I found it ! Thank you very much for your help.
It seems that there was a conflict between privatemsg_rules and Node Limit. I will try Node Limit Number which has rules support now and is still in development. I will post back.Edit : Oops, I was already using node limit number, not node limit. So the conflict is with Node Limit Number 6.x-2.0-alpha3 and 6.x-2.x-dev from 2010-Feb-25.
Comment #8
ethnovode commentedDo you want me to open a bug report in the node limit number issue queue or could this be fixed by you ?
Comment #9
berdirOk, I found the issue.
Default rules need to have unique name or they are merged in a strange way that breaks things. By default, rules uses the id of the rule in the database, so you have for exaple "rules_2", but that is obviously not unique if another module does the same.
I renamed the two default hooks, the attached patch should fix this for you. I suggest that you open a new bug report for node_limitnumber too, suggesting that they rename their defaults too since this could happen with every module that keeps these default names.
You could even think about creating a bug report for rules.module which could try to figure out that something is wrong with the default defintition and display a warning/error instead of a fatal error.
Please try the patch and set to RTBC once you've tested it, thanks.
Comment #10
ethnovode commentedExcellent, nice catch. That was indeed the problem, your patch works fine, I don't see warnings anymore and the fatal error is gone.
I will post back to rules and node limit number, thank you very much.
Comment #11
berdirGreat, thanks for the fast responses and your testing! I will commit the patch soon.
Please report any bugs you notice in the 2.x-dev release, I'm sure there are a few and testers are always needed :)
If you want to help with future development of the module, it would also be great if you can test features you're interested in from the issue queue.
Comment #12
berdirCommited to 6.x-2.x, thanks for reporting!