Closed Mai-Saad closed 3 months ago
Umm, from my tests, here are some complementary informations:
Auto-Optimize images on upload
but AVIF
is disabled, when we upload images it gets optimized on upload, and get this status in the DB (wp_postmeta
):meta_key | meta_value |
---|---|
_imagify_status | already_optimized |
Because of this, when we enable AVIF
and save, it gets to this line where we get the unoptimized media_ids
. However, as the status says already_optimized
it won't return these images IDs.
Auto-Optimize images on upload
, upload images, and we enable AVIF
and save, it will generate .avif
files. So the problems lies in the fact that Auto-Optimize images on upload
set the status at already_optimized
so images aren't getting picked up by the bulk optimization when we save with AVIF
enabled.
@Miraeld Could you check how this button works in the current version? The behaviour should be very similar
I've compared a bit with develop
branch.
From what I am seeing,
Auto-optimized
is disabled, and we upload an image, we don't get the status already_optimized
in the DB.
It means we have a problem here with the AVIF
branch. @piotrbak I've tried to check the button, but it is also not working on avif
branch, and I was trying to debug it on develop
to see how it works, and why we could get an error, but once i clicked it one time it disappeared forever, even when I upload new images which aren't optimized. So not sure yet, I'm trying to figure out the differences between develop
and avif
on the upload part.
If we have single large image in media library then enabled AVIF, the AVIF won't be generated in background (tested local using attached image) @Miraeld can you please check if it's working for this image? (note: bulk notice wasnot displayed in this case)
@Mai-Saad , I've created this PR https://github.com/wp-media/imagify-plugin/pull/811 to take care of this last feedback.
Before submitting an issue please check that you’ve completed the following steps:
Describe the bug When enabling AVIF, it isnot automatically generate AVIF for existing images in the media library
To Reproduce Steps to reproduce the behavior:
Expected behavior AVIF version is generated and quota is affected
Additional context Add any other context about the problem here.
Acceptance Criteria (for WP Media team use only) Clear instructions for developers, to be added before the grooming