Warning: array_merge() [function.array-merge]: Argument #1 is not an array in /home/public_html/modules/relationship/relationship_api.inc on line 303

Warning: Invalid argument supplied for foreach() in /home/public_html/modules/relationship/relationship_api.inc on line 315

Warning: array_merge() [function.array-merge]: Argument #1 is not an array in /home/public_html/modules/relationship/relationship_api.inc on line 303

Warning: Invalid argument supplied for foreach() in /home/public_html/modules/relationship/relationship_api.inc on line 315

Comments

jazzitup’s picture

After setting up "administer > settings > relationship", selecting the story node type, this issue is reported while trying to edit a "story node":

shouldn't get here, rendering statements for a node that should have been initialized but wasn't

: in relationship_form(), line 267 administer_relationships.inc : in relationship_form_alter(), line 198 administer_relationships.inc : in drupal_get_form(), line 117 form.inc : in node_form(), line 1586 node.module : in node_page(), line 2059 node.module : in menu_execute_active_handler(), line 418 menu.inc 0.00s elapsed. (0 total)

jazzitup’s picture

Title: Warnings » Relationship is not working?!
Priority: Normal » Critical

Hm... after trying to save changes to a story node, this one breaks the page completely!

shouldn't get here, rendering statements for a node that should have been initialized but wasn't
: in relationship_form(), line 267 administer_relationships.inc : in relationship_form_alter(), line 198 administer_relationships.inc : in drupal_get_form(), line 117 form.inc : in node_form(), line 1586 node.module : in node_page(), line 2059 node.module : in menu_execute_active_handler(), line 418 menu.inc 0.00s elapsed. (0 total)

dman’s picture

I've had this happen a bit myself when testing different ways of making nodes.
Seems like I assumed that node_load() would always happen before node_update(), but that's not always so. That message was just a debug note anyway, left there to identify just WHEN this odd circumstance would happen, so I could analyse it.

I'm guessing it was during a 'Preview' button press on a new node?

Anyway, I've patched CVS a bit to stop it complaining about that.

I also think I fixed the first issue this week. Should be in CVS.

jazzitup’s picture

Version: 4.7.x-1.x-dev » master

1) No, I didn't use the Preview button - I used Submit button directly.
2) Now I used your new CVS version and this is an error when I try to submit another story node:

Fatal error: Cannot work with a resource with no name identifier at all! Problem saving statements for Array ( [nid] => 5 [vid] => 5 [uid] => 1 [created] => 1160862480 [type] => story [changed] => 1160862480 [title] => AAA1 [body] => XXX2 [format] => 1 [name] => jazz [date] => [status] => 1 [moderate] => 0 [promote] => 1 [sticky] => -100 [revision] => 0 [preview] => Preview [submit] => Submit [form_id] => story_node_form [comment] => 2 [menu] => Array ( [title] => [description] => [pid] => 1 [path] => [weight] => 0 [mid] => 0 [type] => 86 ) [og_public] => 1 [statements] => Array ( [_comesAfter_node_3] => Array ( [subject] => [predicate] => comesAfter [depth] => [rsid] => [title] => WForms Tes in /home/public_html/modules/relationship/relationship_api.inc on line 1410

dman’s picture

Status: Active » Closed (fixed)

Long fixed or dead. Time to clean up the queue.