Posted by chowdah on June 8, 2010 at 12:48am
18 followers
| Project: | ImageAPI |
| Version: | 6.x-1.10 |
| Component: | ImageAPI Imagick |
| Category: | bug report |
| Priority: | normal |
| Assigned: | Unassigned |
| Status: | active |
Issue Summary
user error: ImageMagick reported an error: in /[PATH TO ROOT]/sites/default/modules/imageapi/imageapi_imagemagick.module on line 224.
I upgraded my image api module recently and am sporadically getting these error messages after creating a post that uses imagefield to upload and imagecache to create derivative images. I replaced the path to my actual drupal root with [PATH TO ROOT] above.
If I read line 224 correctly, this is a error that throws when Imagemagick returns a something besides a 0 - but there is little other info I can glean from this. Where do I look for more info to fix this 'error' - if it is one?
BTW I'm using Drupal 6.17
Comments
#1
I'm having the same issue. The output of the debug option is
ImageMagick command: /usr/bin/convert -versionImageMagick output: Version: ImageMagick 6.2.8 04/17/08 Q16 file:/usr/share/ImageMagick-6.2.8/doc/index.html Copyright: Copyright (C) 1999-2006 ImageMagick Studio LLC
#2
Subscribing.
Same error for me.
#3
subscribing :(
#4
Wrong checking for return code of imagemagick, patch attached.
#5
Thanks, I have applied the patch and the message is gone.
#6
#7
After upgrading ImageAPI to the latest Jul 11th dev I had to re-apply this patch as I was getting this error again, and the patch worked.
So I'm assuming this patch never made it to the new dev codebase or whatever. Just thought I'd mention it.
#8
Patch in #4 still applies and fixes the issue in latest 6.x-1.x-dev (2010-Jul-11).
... come on people, this is RTBC for almost 2 months now! Please get it in at least in a dev version.
#9
This was went in with #803760: _imageapi_imagemagick_convert_exec() should not display any text on stderr as errors.
#10
Thanx Andrew! Good to have you back ;)
#11
you're welcome, trying to clear things up. really need to dig into the imagecache queue :(
#12
I'll see if I can spare some of my almost-non-existent free time (got an extra day-job now) to help you there. ...you know, I can do things link ping some people about old issues and test some of them against latest stable version + dev to see if they still stand.
#13
Seems my errors are gone since upgrading! Thanks!
#14
Hello,
I get a similar error:
user error: ImageMagick reported error code 9. in ../sites/all/modules/imageapi/imageapi_imagemagick.module on line 227.
This is what I did to provoke the error:
1. new content type with CCK image field
2. new page of this content type with uploaded image file
I see that the image file is actually uploaded and viewable on the website as it should, so why the error? I have 755 permission set on my files folder on the server.
Another issue that I have is that if I want to make drupal save the image files in a subfolder named after the content type in the files folder using filefield path, it tends to create a folder named [type] instead of the actual name of the content type .... hmmmm? I believe the syntax is correct for path setting for the image field. Could it be related to the above error?
I am using
Drupal core 6.19
Content Construction Kit (CCK) 6.x-2.8
FileField 6.x-3.7
FileField Paths 6.x-1.4
Image 6.x-1.0
ImageAPI 6.x-1.9
ImageCache 6.x-2.0-beta10
ImageField 6.x-3.7
#15
Hello,
I have the same error except the error code is -1.
I have the last dev version of imageapi...
Thanks a lot for your help !
#16
Automatically closed -- issue fixed for 2 weeks with no activity.
#17
I bet this is far from fixed yet ;)
...if the bot closes it again (due to inactivity) I'll just set it to postponed.
#18
klonos, please read #9 and don't re-open this unless you can clearly explain how this is still a problem.
#19
Sorry about that Andrew, I keep quite a few test setups around where I am able to reproduce certain issues so I can help with the issue queues. I was still getting this in the setup I was maintaining for this specific issue here, but I just noticed that it was rolled back to a previous backup somehow. My bad.
#20
No worries. Thanks for the testing.
#21
same error for me too, except the on line 227
I think it has to do something with allocated memory in a shared hosting environment... I wasn't getting this on a dedicated server, but on a shared server (with low amount of memory allocation) I was getting intermittent error from imagecache, then noticed this error in ImageAPI...
#22
I am getting this error as well
user error: ImageMagick reported error code 1. in /xxxxx/sites/all/modules/imageapi-6.x-1.9/imageapi/imageapi_imagemagick.module on line 227.
#23
Having the same error
drupal ImageMagick reported error code 1. in /var/www/html/mysite/sites/all/modules/imageapi/imageapi_imagemagick.module on line 227.
Randomly appears and a complete fresh install with the latest versions.
#24
Same problem here
user error: ImageMagick reported error code 1. in /var/aegir/drupal-6.20/sites/www.example.com/modules/imageapi/imageapi_imagemagick.module on line 227.For some reason imagemagick is returning status code 1 for simple version check
~$ convert -version
Version: ImageMagick 6.4.5 2009-06-04 Q16 OpenMP http://www.imagemagick.org
Copyright: Copyright (C) 1999-2008 ImageMagick Studio LLC
~$ echo $?
1
#25
I only found this comment that might explain what is going on http://omeka.org/forums/topic/installation-on-mac-os-x-1055#post-1133 it seems that imagemagick returns status code 1 when running without any arguments which version checking is. I'm attaching a patch that handles it not sure tough if this is the way to go.
#26
Rerolled patch with my correct git details hope I did it right this time.
#27
#28
The patch in #26 fixes the issue.
#29
Make a small change to the structure for clarity.
#30
committed to 6.x-1.x
#31
Automatically closed -- issue fixed for 2 weeks with no activity.
#32
I have updated to ImageCache 6.x-2.0-beta12 and am still getting user error:
ImageMagick reported error code 9. in /[PATH TO ROOT]/sites/all/modules/contrib/imageapi/imageapi_imagemagick.module on line 236.
ImageCache 6.x-2.0-beta12 is dated 2011-May-16 and am wondering if it included the patch detailed above.
Also wondering if the patch dealt with error code 9 (or just error code 1).
Other info:
Drupal core 6.22
Content Construction Kit (CCK) 6.x-2.9
FileField 6.x-3.10
ImageAPI 6.x-1.10
ImageCache 6.x-2.0-beta12
ImageCache Actions 6.x-1.8
ImageField 6.x-3.10
ImageField Focus 6.x-1.3
#33
Same error with Imagecache 2.x-rc1, except that error code is 11 instead of 1 or 9.
ImageMagick reported error code 11. in /[path]/sites/all/modules/imageapi/imageapi_imagemagick.module on line 231.EDIT: debugging info from Imagemagic
ImageMagick command: /usr/bin/convert 'sites/default/files/userspics/picture-489.jpg' -resize 220x220! -crop 220x165+0+27! -unsharp 0.5x0.5+1+0.05 -quality '80' 'sites/default/files/imagecache/preview/userspics/picture-489.jpg'ImageMagick output:
Version: ImageMagick 6.5.4-7 2012-05-07 Q16 OpenMP http://www.imagemagick.org
#34
Update: the culprit seems to be the Crop action combined with Sharpen.
Using Scale + Sharpen does work, but any combination of Scale and Crop + Sharpen, or Scale + Crop + Sharpen leads to the error.
Setting Crop as the last action (Scale + Sharpen + Crop) does work though.
Thanks
#35
I'm having this error message
user error: ImageMagick reported error code -1. in /home/myweb/ht_docs/drupal/sites/all/modules/imageapi/imageapi_imagemagick.module on line 227.I'm using a web hosting