The D7 port patch I submited had a problem witch results in creating a download directory for each preset.

Since derivatives are handled by imagecache, there is no need to create a new directory to store the original image.

This patch resolves this issue and a case when drupal_http_request() returns no data.

Comments

7wonders’s picture

you missed a closing bracket on line 124 with that patch.

manu manu’s picture

Thanks 7wonders,

Here is a correction.

summit’s picture

Hi, would it also be possible to only cache on a hit?
greetings, Martijn

martysteer’s picture

This patch works well for me too. Thankyou!

manu manu’s picture

Status: Needs review » Reviewed & tested by the community

@Summit Not with the design of the current branch.

@martysteer Thanks, marking as RTBC

summit’s picture

Hi,
After applying this patch I got for a lot of my nodes with a link-imagefield with imagecache external:

Unable to generate the derived image located at public://styles/medium/public/imagecache/medium/externals/[imagenumber-cache]

I see the imagecache/externals folder has Permission: 775. I can't change that manually.

Could this Notice have to do with this patch please?
Greetings and thanks for your reply, Martijn

BarisW’s picture

Status: Reviewed & tested by the community » Needs work

I think it would be a good thing to keep the $preset in the $directory. Else, the cached files are overwritten if you use several image styles to display the same image.

Rest of the patch is great, and solves my problem.

BarisW’s picture

Priority: Normal » Major

And marking this major. Caching is the base of this module ;)
It solves #1508078: Files are recreated on every page load as well.

BarisW’s picture

Status: Needs work » Reviewed & tested by the community

Re #7: I think I was wrong. Image styles adds the preset by default. So it already works fine. Thanks for the patch, please commit!

manu manu’s picture

@ Summit: I can't say... I use it on 500k entities and the errors I could see are related to 404, 503....

@ BarisW : ah great, you're saving me the time to jump into the code.

I'm not the module maintainer, i can't commit but sure @larowlan will have a look on this.

larowlan’s picture

Status: Reviewed & tested by the community » Fixed

Committed, thanks Barisw and manu manu

Status: Fixed » Closed (fixed)

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