Hi,
Why do I get the following error message after installing this:

Fatal error: Call to undefined function: uc_product_node_info() in /home/vikjffmw/public_html/gamezone/modules/ubercart/uc_repeater/uc_repeater.module on line 48

Comments

Adds’s picture

Can anyone advise on this please?

Shawn Conn’s picture

Status: Active » Closed (fixed)

See your post on ubercart.org.

seanr’s picture

Version: 5.x-1.0-beta5 » 5.x-1.5
Component: Website » Code
Category: support » bug
Status: Closed (fixed) » Active

The problem here appears to be an installation order issue. I think maybe the module weights need to be adjusted so that the required core modules (product/cart/etc.) always get loaded before the others. Otherwise, it's damned near impossible for a non-expert to install this module. Order of installation should never cause a fatal error because the modules should be weighted correctly and have the correct dependencies set.

seanr’s picture

Title: Urgent - Error Message - Help Please!!! » Fatal error: Call to undefined function: uc_product_node_info()
Island Usurper’s picture

But the Ubercart modules do have all their dependencies set. In fact, I enable them all at once and I have never had this problem. rszrama has, so I've seen it happen, but I can't debug what I can't duplicate. I've looked at Drupal's module installation code, but it looks alright to me.

I just had the thought that maybe we shouldn't be declaring dependencies of dependencies in the .info files. For example: module C depends on B which also depends on A. Would the following line in C.info cause problems?

dependencies = A B

I would not expect it to, but I would acknowledge that it isn't the best practice.

rszrama’s picture

Version: 5.x-1.5 » 6.x-2.x-dev
Priority: Critical » Minor
Status: Active » Postponed (maintainer needs more info)

fwiw, people following the installation instructions in our documentation will see that they should install the 4 core modules before installing any other modules. We can't force them to do so, but it has been documented. Basically, this is a Drupal issue, not an Ubercart issue... but I don't have the slightest clue on how it should be addressed at the Drupal level. Someone suggested that what's happening is it's going by folder name... so the quote module will get enabled first since it's in the shipping subdirectory which gets loaded before uc_product... but still, it shouldn't be an issue. : ?

EDIT: Oof... my old docs on installation mentioned the install order; I think Shawn took that out in a rewrite. Leaving this open so I can update them. : (

rszrama’s picture

Version: 6.x-2.x-dev » 6.x-2.0-beta1
Component: Code » Documentation
Status: Postponed (maintainer needs more info) » Fixed

Status: Fixed » Closed (fixed)

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

plasticlax’s picture

so when doing an update should one disable all but the 4 core modules first? doesn't that reset all kinds of settings? i am getting this error on only one of several sites after doing an update to 5.x 1.7
to solve it i deleted the shipping folder, ran update.php, then reuploaded the shipping folder and ran update.php again.