Open Mosnar opened 1 week ago
@bymayo I reverted this change, switching back to $asset->getContents()
and tested the following scenarios trying to reproduce the issue:
None of these scenarios caused any errors. Were you running the code on Servd when you got this error or were you running locally using a Servd volume?
For the moment, I've pushed a commit reverting back to the old getContents method, as I think it's a cleaner API for us to use. I haven't tagged a release yet because I'd like to get to the bottom of your error.
@Mosnar I was running it locally, hooking in to Servd on a DDEV environment.
I'll use this release and see if i can figure out the issue a bit better.
@Mosnar I was running it locally, hooking in to Servd on a DDEV environment.
I'll use this release and see if i can figure out the issue a bit better.
Thanks! One thing worth checking is that your Servd asset storage environments are in-sync. If you're using a copy of the production database but using staging assets, it's possible an asset is missing.
I wasn't sure if this was because we were using Servd and their remote storage and it was struggling to grab the image.
I suppose if you want to keep the way i've done it, you could just pass the
path
rather than theurl
if some filesystems don't have public URL'sOriginally posted by @bymayo in https://github.com/venveo/craft-compress/issues/29#issuecomment-2373312730