Problem: in the "Add a new condition" form page, when I click on the "Continue" green button, it doesn't do anything.

I see the following 2 entries in the Recent log message:

Referrer: http://myserver.com/admin/config/workflow/rules/reaction/manage/rules_te...
Message: Notice: Undefined index: properties in RulesData::addSiteMetadata() (line 620 of /mydrupal/sites/all/modules/rules/includes/rules.state.inc).

Referrer: http://myserver.com/admin/config/workflow/rules/reaction/manage/rules_te...
Message: Invalid form POST data.

So upon debugging rules.state.inc, I determined that $site_info['properties'] is unset. So I added a check before that line:

if ( isset ( $site_info['properties'] ) )
$property_info['properties'] += $site_info['properties'];

and that fixed the problem; now when I click on the "Continue" green button, it shows me additional configuration stuff.

Support from Acquia helps fund testing for Drupal Acquia logo

Comments

justdave’s picture

I'm not sure this is the right fix. Looking at the code it looks like $property_info is the main object being operated on here, and it's supposed to be getting passed in by the caller. Whatever's calling it in this instance is failing to pass it in correctly, and that's where the fix needs to happen...

betz’s picture

I can confirm this, and your fix also fixed this issue i got #1842012: AJAX returns parsererror - I cannot use this module

timaholt’s picture

I had this same issue on the AJAX returns parsererror thread, and here's a patch that should work against 7.x-2.2

Torenware’s picture

JustDave may be right.

I was running the UUID module, and its current released version has a bug (fixed in dev) that clobbers the property info information for _all_ of your modules. Once hook_entity_property_info_alter is called, you are hosed.

Arguably Rules should check its input better, but this is why the patch sort of works, but not quite.

michlis’s picture

I have same problem with Rules and AJAX. Unfortunately, patch from #3 didn't work for me.
Site I am working on might have had UUID installed in the past, but I am not sure.
Any ideas how to debug it further? Can IIS be a problem here too?

krutibhakta’s picture

Thanks! that work for me!

maxplus’s picture

Hi,

patch for me also worked to get rid of my ajax error when trying to add the action "Set data value"

Thanks!

maxplus’s picture

I disabled the patch again because the ajax dynamic drop down selector to select a variable didn't appear anymore...
Now I unistalled the UUID module and everything is working again.

fishfree’s picture

Thank you, it works for me.

FaintRush’s picture

Had the same problem, patch #3 seems to help
Thanks

PatchRanger’s picture

rukayya’s picture

hey #3 is really too good,it really helped me a lot :)

TR’s picture

Issue summary: View changes
Status: Active » Closed (outdated)

@Torenware accurately summarized the problem in #4. This was being caused by a problem in the UUID module. UUID has since fixed the problem, and there haven't been any additional reports of this problem for more than 5 years now.

If you find this is still a problem, please open a new issue with details for how to reproduce the error.

lbrassaw’s picture

The patch resolves the issue I've been getting: Error: Unsupported operand types in RulesData::addSiteMetadata() (line 648 of /sites/all/modules/contrib/rules/includes/rules.state.inc).

Was not using UUID module, but tried installing it just in case, which didn't resolve the issue.