This occurs when replying to a comment on a blog post. Expected no error, instead got this:

Fatal error: Unsupported operand types in /usr/home/hoslo/public_html/includes/common.inc on line 1275

MySQL database 4.1.22
MySQL database for event module 4.1.22
PHP 4.4.7
PHP memory limit 256M
Web server Apache/1.3.37 (Unix) mod_choke/0.07 mod_fastcgi/2.4.2 mod_gzip/1.3.26.1a mod_auth_passthrough/1.8 mod_log_bytes/1.2 mod_bwlimited/1.4 FrontPage/5.0.2.2635.SR1.2 PHP-CGI/0.1b

CommentFileSizeAuthor
#7 comment_error.txt83.43 KBStarminder

Comments

dave reid’s picture

Status: Active » Postponed (maintainer needs more info)

Since no one else has reported this problem in 6.6 yet, most likely your problem is a contrib module not using the proper implementation of url and the $options parameter array. The problem is from:

function url($path = NULL, $options = array()) {
  // Merge in defaults.
  $options += array(
    'fragment' => '',
    'query' => '',
    'absolute' => FALSE,
    'alias' => FALSE,
    'prefix' => ''
  );

What contrib modules are you using?

Starminder’s picture

It's a long list - trying to think of wht might interact with comments, but it's just not obvious to me...

ACL 6.x-1.0-beta2
Includes: ACL

Advertisement 6.x-1.x-dev (2008-Oct-31)
Includes: Ad, Click filter, Embed, External Ad, File cache, HTML Ad, Image Ad, Notify, Remote, Report, Text Ad

Drupal Administration Menu 6.x-1.1
Includes: Administration Menu

AdSense 6.x-1.0-beta2
Includes: AdSense core, Ads (old), CSE Search, Managed ads, Revenue sharing basic (old), Search (old)

Advanced help 6.x-1.1
Includes: Advanced help, Advanced help example

Announcements 6.x-1.2
Includes: Announcements

Avatar Selection 6.x-1.5
Includes: Avatar Selection

Block Theme 6.x-1.0-beta1
Includes: Block Theme

Buy Me a Beer 6.x-1.0
Includes: Buy me a beer

Calendar 6.x-2.0-rc4
Includes: Calendar, Calendar Popup, Calendar iCal

CAPTCHA 6.x-1.0-rc2
Includes: CAPTCHA, Text CAPTCHA

Comment Notify 6.x-1.1
Includes: Comment Notify

Content Construction Kit (CCK) 6.x-2.0-rc10
Includes: Content, Content Copy, Content Permissions, Fieldgroup, Node Reference, Number, Option Widgets, Text, User Reference

Daily 6.x-1.1
Includes: Daily

Dash Media Player : a media player built for Drupal CMS 6.x-1.1
Includes: DASH Player, Tagging Service, Voting Service

Date 6.x-2.0-rc4
Includes: Date, Date API, Date Copy, Date PHP4, Date Popup, Date Repeat API, Date Timezone

Read More Tweak 6.x-3.x-dev (2008-Aug-13)
Includes: Read More Tweak

Event 6.x-2.x-dev (2008-Oct-26)
Includes: Event

Fasttoggle 6.x-1.3
Includes: Fasttoggle

Services 6.x-0.13

Includes: File Service, Menu Service, Node Service, Search Service, Services, System Service, Taxonomy Service, User Service, Views Service, XMLRPC Server

Fivestar 6.x-1.13
Includes: Fivestar, Fivestar Comments

FlashVideo 6.x-1.4-beta4
Includes: FlashVideo, FlashVideo Amazon S3 Plugin, FlashVideo CCK, FlashVideo Views

Image 6.x-1.0-alpha3
Includes: Image, Image Attach, Image Gallery, Image Import, ImageMagick Advanced Options

Image FUpload 6.x-1.1-rc1
Also available: 6.x-3.x-dev (2008-Oct-30)

Includes: Image FUpload, Image FUpload (image)

IMCE 6.x-1.1
Includes: IMCE

Lightbox2 6.x-1.8
Includes: Lightbox2

Live 6.x-1.0
Includes: Live

Mail editor 6.x-1.x-dev (2008-Oct-07)
Includes: Mail Editor

Pathauto 6.x-1.1
Also available: 6.x-2.x-dev (2008-Sep-13)

Includes: Pathauto

album photos 6.x-1.4-beta2
Also available: 6.x-2.5-beta3 (2008-Oct-09)

Includes: album photos

phpBBforum Integration module 6.x-1.03
Includes: phpBBforum

Pingback 6.x-1.0
Also available: 6.x-2.x-dev (2008-Aug-14)

Includes: Pingback

Poormanscron 6.x-1.0
Includes: Poormanscron

Printer, e-mail and PDF versions 6.x-1.0
Includes: PDF version, Printer-friendly pages (core), Send by e-mail

Quote 6.x-1.1-beta
Includes: Quote

Banner Rotor Module 6.x-1.3
Includes: Rotor

Scheduler 6.x-1.2
Includes: Scheduler

Service links 6.x-1.0
Includes: Service links

Signatures for Forums 6.x-1.0-alpha1
Includes: Signatures for forums

Site map 6.x-1.x-dev (2008-Oct-24)
Includes: Site map

Subscriptions 6.x-1.0-beta3
Includes: Blog Subscriptions UI, CCK Fields, Content Subscriptions, Subscriptions, Subscriptions Mail, Subscriptions UI, Taxonomy Subscriptions

Tagadelic 6.x-1.0
Includes: Tagadelic

Taxonomy Manager 6.x-1.0-beta2
Includes: Taxonomy Manager

Theme Settings API 6.x-1.4
Includes: Theme Settings API

Thickbox 6.x-1.0
Includes: Thickbox

Tiny Tiny MCE 6.x-1.9
Includes: Tiny Tiny MCE

Token 6.x-1.11
Includes: Token, Token actions

User Stats 6.x-1.0-alpha1
Includes: User Stats

User Points 6.x-1.x-dev (2008-Oct-08)
Includes: Userpoints, Userpoints Basic

Video Filter (YouTube, Google Video, Godtube and more...) 6.x-2.4
Includes: Video Filter

Views 6.x-2.1
Includes: Views, Views UI, Views exporter

Voting API 6.x-2.0-rc1
Includes: Voting API

Webform 6.x-2.3
Includes: Webform

Web Links 6.x-1.1
Includes: Web Links, Web Links Filter

Wikitools 6.x-1.0
Includes: Wikitools
Themes

Aboutpeople 6.x-1.1
Includes: About

Marinelli 6.x-2.3
Includes: Giordani

dave reid’s picture

With that many modules, your best bet is going to disable each one at a time and find out which module is causing the problem. The only other option is if you're comfortable making a small change to the Drupal core files:

Changing includes/common.inc around line 1267:

function url($path = NULL, $options = array()) {
  // Add these four lines:
  if (!is_array($options)) {
    drupal_set_message('$options is not an array: '. var_export($options, TRUE));
    drupal_set_message('backtrace: '. var_export(debug_backtrace(), TRUE));
  }
  ...

Once this is changed, you can perform the same action that's causing the error and copy-paste the results from the message boxes here.

Starminder’s picture

Status: Postponed (maintainer needs more info) » Fixed

Well, let's see....turn off 427 modules one at a time or copy and paste 4 lines of code. Decisions, decisions.... I opted for the code, and the good news is.....*drumroll please* Problem solved!! Will continue testing, but it is looking good.

Thank you!! (please commit)

Starminder’s picture

Status: Fixed » Needs work

Got another one just now:

Fatal error: Unsupported operand types in /usr/home/hoslo/public_html/includes/common.inc on line 1279

Also got 3 pages of output afterward. If you need more to go on just holler. Thanks!

stevenpatz’s picture

yes the three pages of info would be helpful.

Starminder’s picture

StatusFileSize
new83.43 KB

I've attached a text file capture of the resulting mess on the screen once you return to the site after the fatal error - hope it helps!

dave reid’s picture

Project: Drupal core » Comment Notify
Version: 6.6 » 6.x-1.1
Component: comment.module » Code
Status: Needs work » Active

I think I can narrow this down to the comment_notify module. Please try the latest development version. It looks like there were a few url() call bugs in 6.x-1.1 that were using the 5.x parameter syntax.

Also, this spelling error for 'absolute' needs to be fixed in comment_notify.module HEAD. Sorry I don't have a line number since I'm just viewing in WebCVS.

'!login_uri' => url('user', array('ablsolute' => TRUE)),

Would it be possible to get out a 6.x-1.2 bugfix release since there are lots of 5.x calls to url() in 6.x-1.1?

greggles’s picture

Title: New Fatal error when leaving comments » ablsolute instead of absolute
Status: Active » Fixed

Thanks, Dave Reid.

You can see the line numbers on the annotate view.

I've fixed that issue. There are a few more bugs in the queue with "patch code needs review" that I'd like to fix before a 6.x-1.2. Any chance you could review those?

dave reid’s picture

How have I lived so far without knowing about annotate? I'll try and take a look at some of them today.

Starminder’s picture

Hi - I went to the dev version, and prior to install looked for the typo, someone else took care of it already. Dev version installed and working like a charm so far, thanks I really appreciate the quick help!!

Status: Fixed » Closed (fixed)

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