I see a lots of warnings in my watchdog table such as:
Type: imagecache
URL: http://www.obruch.com.ua/cron.php
Msg: Cached image file sites/obruch.com.ua/files/imagecache/menu_icon/menu_icons/menu_icon_2628.jpg already exists but is being regenerated. There may be an issue with your rewrite configuration.

Poormanscron used. Messages are diffenet only by menu icon number.

What could be wrong in my configuration?

CommentFileSizeAuthor
#7 menu_icons-871560-no_regeneration.patch924 bytesjmcintyre

Comments

deadman’s picture

I was seeing the same thing in my error log. Basically this module is forcing imagecache to regenerate the menu icons unnecessarily. The way imagecache works is when an appropriate cached image is called, it will serve the image or generate it if it doesn't exist. This module is calling the regenerate function all the time which can cause problems especially if you use a lot of menu images.

To solve it, comment out or remove line 238 from menu_icons.module.
change this:

imagecache_build_derivative($preset['actions'], $options['menu_icon']['path'], $path);

to:

//imagecache_build_derivative($preset['actions'], $options['menu_icon']['path'], $path);

or just remove that line entirely.

Nick Fedchik’s picture

deadman, thank You, I comment out the line and will observe of updatings in dblog.

okokokok’s picture

Uncommenting that line stops the messages from disappearing but it probably breaks the creation of the icons.

deadman’s picture

No it doesn't, the icons are created by imagecache (if necessary) when they are requested. They don't have to be specifically regenerated.

okokokok’s picture

Ok, so if the line can be removed without any problems, it's time to remove that line from the module and release a next stable version...

jmcintyre’s picture

subscribing

jmcintyre’s picture

Status: Active » Needs review
StatusFileSize
new924 bytes

Patch attached per #1. Tests fine for me - no errors in dblog after creating or deleting a menu icon, or after running cron.

Nick Fedchik’s picture

No more warnings.

hansrossel’s picture

Status: Needs review » Reviewed & tested by the community
saurabhk_97’s picture

Thanks deadman. Commenting out the one line code worked. Regards.

chicagomom’s picture

This patch is still needed, has not yet been applied to the module.

lambic’s picture

We are seeing these errors too, any chance of a new D6 stable version?

fonant’s picture

I too have this problem, the patch fixes it.