Closed (fixed)
Project:
ImageCache Actions
Version:
6.x-1.1
Component:
Custom Actions Module
Priority:
Normal
Category:
Bug report
Assigned:
Unassigned
Reporter:
Created:
31 Jan 2009 at 01:03 UTC
Updated:
23 Jul 2011 at 01:50 UTC
Fatal error: Call to undefined function imagecache_action_definitions() in imagecache_coloractions.install on line 8
Comments
Comment #1
pasqualleComment #2
jfxberns commentedI experienced the same problem but with the imagecache_customactions module install.
Fatal error: Call to undefined function imagecache_action_definitions() in /home/tguide6/public_html/sites/all/modules/contrib/imagecache_actions/imagecache_customactions.install on line 8
The problem only occurs on the first attempt at installing the module ONLY IF it's installed at the same time as imagecache; installations always works fine--once imagecache has already been installed.
The problematic install module code is as follows:
Line #8
refers to a function in imagecache.module (Line #222) that, I am guessing, is not registered because the module is not installed yet, even though it is properly specified as a dependent module in the imagecache_customactions.info file.
It seems to be related to this system.module bug (http://drupal.org/node/151452) where installation of dependent modules are not executed in the proper order.
I have noted this issue and reffered to this bug in that bug report.
Comment #3
dman commentedLooks like a simple function_exists() check should fix that.
If imagecache DOES boot afterwards, it will do its own scanning like this, so the job will get done. The code is only there to force imagecache to recognize it if it was installed subsequently.
Comment #4
dman commentedFixed in -dev
Comment #6
baisongTrying to use 5.x-2.3 and get the same error for imagecache_canvasactions:
In imagecache_canvasactions.install I changed
to
...and then it installed!
Comment #7
baisong...but actually... it doesn't seem to have successfully installed. all i have in my imagecache preset dropdown is the normal scale, resize & crop...
Comment #8
dman commentedThat function call triggers a cache refresh that alerts the UI to the fact that there are new presets available...
If the function is disabled, the cache still needs to be flushed.
Often disabling and re-enabling things makes that works.
... but normally ... tht function call in the hook_enable was expected to do it for you :-/