After upgrading core from 6.12 to 6.14, accessing the Drupal SMS Framework module yields to this error:

Fatal error: Unsupported operand types in [...site_path...]/modules/system/system.module on line 627

Found a hint in this issue #471964 : Rules administration menu broken - Fatal error: Unsupported operand types in modules/system/system.module on line 626

Line 626 from system.module :

$item += db_fetch_array(db_query("SELECT mlid, menu_name FROM {menu_links} ml WHERE ml.router_path = '%s' AND module = 'system'", $item['path']));

As stated in the above issue:

The error seems to be caused by db_fetch_array returning false. $item['path'] has the value of admin/rules. I constructed the query myself and ran it, the query returned no rows.

I ran a sql querry on the drupal database:

SELECT mlid, plid, menu_name, link_path, router_path, link_title FROM menu_links ml WHERE ml.router_path like 'admin/smsframework%' AND module = 'system'

This led to the folowing result:

mlid 	plid 	menu_name 	link_path 							router_path 						link_title
1547 	206 	navigation 	admin/smsframework/actions 			admin/smsframework/actions 			SMS Actions
1636 	1547 	navigation 	admin/smsframework/actions/edit 	admin/smsframework/actions/edit 	Edit command
1537 	206 	navigation 	admin/smsframework/gateways 		admin/smsframework/gateways 		Gateway configuration
1623 	1537 	navigation 	admin/smsframework/gateways/% 		admin/smsframework/gateways/% 	 
1551 	206 	navigation 	admin/smsframework/sendtophone 		admin/smsframework/sendtophone 		Send to phone
1549 	206 	navigation 	admin/smsframework/sms_user 		admin/smsframework/sms_user 		SMS User

Obviously the root menu link admin/smsframework isn't there. When I tried admin/smsframework/gateways the Gateways admin page showed up.

I've also tried to reinstall SMS Framework module to fix the problem with no success.
Actually, as SMS Framework module comes with no uninstall script, except for SMS User sub-module, the database tables and entries related to the removed module are not cleared, and running update.php did not create the missing entries.

Is there a way to add the missing records to the database?

Thanks’ a lot.

Comments

aspope’s picture

Assigned: Unassigned » aspope

I see that this issue is currently being tracked in http://drupal.org/node/595724

It has been a few months since you posted this. Have you fixed your issue? How did you do it?

A module disable+enable *should* be enough to refresh the Drupal menu router in the case of SMS Framework, but you have already stated that this doesn't fix the problem. If you haven't already, you should try disabling the module then clearing all caches and re-enabling. Also the devel module provides a Rebuild Menu link that will invoke a rebuild. Or you could dig about in the database tables a bit more...(!)

The base smsframework module does not implement any database tables, which is why the Uninstall option is not available. Entries in the system and menu_links database tables are maintained by the Drupal core functions (eg: admin/build/modules).

In any case, I will leave this issue open for a while longer but from what I have seen the issue is more general, and I do not think that smsframework can do anything to resolve it. However if it is found that the module is invoking menu functions badly, then we can bug-fix.

aspope’s picture

Status: Active » Postponed (maintainer needs more info)
univate’s picture

Assigned: aspope » Unassigned
Priority: Critical » Normal
Status: Postponed (maintainer needs more info) » Fixed

closing since not future comments or issues have been reported.

Status: Fixed » Closed (fixed)

Automatically closed -- issue fixed for 2 weeks with no activity.