Closed (fixed)
Project:
OAuth Common (deprecated)
Version:
6.x-1.0-beta5
Component:
Code
Priority:
Critical
Category:
Bug report
Assigned:
Reporter:
Created:
26 Jul 2009 at 23:32 UTC
Updated:
20 Feb 2010 at 17:40 UTC
Seeing the following error on first installing oauth_common. autoload and inputstream modules were already installed without error.
Fatal error: Class 'OAuthCommonHooks' not found in /drupal-6.13/sites/all/modules/oauth_common/oauth_common.module on line 58
environment:
MySQL 5.0.51a
PHP 5.2.4-2ubuntu5.5
Drupal 6.13
autoload 6.x-1.3
inputstream 6.x-1.0
oauth_common 6.x-1.0-beta3
Comments
Comment #1
xolotl commentedis the problem here the same mentioned in this autoload module issue?
http://drupal.org/node/359147
would it be as simple as renaming the include files to load in an alphabetical order that matches their dependencies?
Comment #2
Hugo Wetterberg commentedHi Xolotl,
This has something to do with cache clearing. I'll take a closer look at this, but for now, just clear your cache.
/Hugo
Comment #3
xolotl commentedYou were right. I was able to avoid the error by manually deleting a record from the cache table with a cid of "autoload:" after I had enabled the oauth_common module and encountered the error. Sorry I don't have more info.
Comment #4
robloachHugo, what are your thoughts on merging in the class hooks into the .module file?
Comment #5
Hugo Wetterberg commentedDo you mean skipping the dependency on the autoload module? It looks like it's either that or to programmatically flush the autoload cache entry when the module is enabled. It's just that autoload is such a nice thing to have, thank god that this problem will go away with the code registry.
I've taken a look at this again, and it should probably be solved by adding:
This should probably be done by all modules that use the autoload module.
Comment #6
Hugo Wetterberg commentedOk, update has been committed to CVS and will show up in the dev snapshot.
Comment #7
xolotl commentedLooks like success! I did not encounter the error upon installing the 6.x-1.0-beta4 version. I did have to disenable and reenable the oauth_common module to avoid the error.
Comment #8
Hugo Wetterberg commentedComment #10
smelliott commentedSorry, I installed 6.x-1.0-beta4 and I still get this error.
Drupal 6.13
autoload 6.x-1.3
inputstream 6.x-1.0
oauth_common 6.x-1.0-beta4
Class 'OAuthCommonHooks' not found in /public_html/sites/all/modules/oauth_common/oauth_common.module on line 60
Comment #11
kehan commentedAfraid I'm also getting this - apologies for issue spamming - I'm just upgrading my various services to the latest services and friends modules - love the principal of everything here I must say especially granular access control for individual service methods.
I've also been using drush (a lot), and #547736 indicates that autoload doesn't work when being called from the CLI.
Comment #12
valkum commentedhe wrote that he put this in dev snapshot ;) try the dev version.
Comment #13
kehan commentedApologies - it was actually #547736: Autoload fails with drush, and a need for clearing the cache.
Comment #14
kehan commentedI have discovered that both the 6.x-1.x-dev build and the 6.x-1.0-beta4 build break drupal database updates.
The version from October 12th on github however works fine - I think there has been some refactoring as autoload wasn't working for drupal hooks like hook_user and hook_menu.
Anyway to fix the issues use the version available at:
http://github.com/hugowetterberg/oauth_common
Comment #15
Hugo Wetterberg commentedThis is fixed in the current release.