3

I am building a site using Drupal 7.26.

I get this notice all the time:

Notice: Undefined index: version_major in update_calculate_project_update_status() (line 628 of /XXX/public_html/modules/update/update.compare.inc).

Does someone knows what is the problem, and how to solve this?

Thanks!

2
  • It was tempting to say "post in issue queue, not here". But which module is responsible? Now figuring this out is interesting task. +1 from me.
    – Mołot
    Commented Apr 1, 2014 at 11:18
  • Figuring out the module should be easy, I used a check like if(isset($release['version_major'})){ //output debugging info/variables }. That let me determine the module that was having a problem. IF you need drupal debugging tools, please see my comment below for links.
    – DrCord
    Commented Sep 25, 2014 at 21:58

1 Answer 1

4

If you put:

if(!isset($release['version_major'])) {
    die('<pre>'.print_r($project, TRUE).'</pre>');
}

On line 625 of update.compare.inc then when the version_major is not set it will print out details of the problem module and die.

Once you know what module is causing the problem then remove this code again as otherwise kittens may die.

When you know what module is causing the issue then you can raise the problem in their issue queue.

2
  • 1
    Yes, hacking core for debugging purposes, and reverting back when you are done, is perfectly acceptable when working on weird situations.
    – mpdonadio
    Commented Apr 1, 2014 at 20:12
  • 1
    if you install the devel and devel debug log modules you can output to a debug log easily and inspect the giant crazy objects that drupal creates much easier, essential for debugging. Also, controlled by permissions so need to worry about anyone seeing the output except you.
    – DrCord
    Commented Sep 25, 2014 at 21:25

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.