[wp-trac] [WordPress Trac] #57370: WP_Image_Editor_Imagick creates unexpected 'thumbnail' image size when original image is 150x150

WordPress Trac noreply at wordpress.org
Mon Jan 9 19:01:35 UTC 2023


#57370: WP_Image_Editor_Imagick creates unexpected 'thumbnail' image size when
original image is 150x150
--------------------------------------+------------------------------
 Reporter:  danielbachhuber           |       Owner:  (none)
     Type:  defect (bug)              |      Status:  new
 Priority:  normal                    |   Milestone:  Awaiting Review
Component:  Media                     |     Version:
 Severity:  normal                    |  Resolution:
 Keywords:  has-patch has-unit-tests  |     Focuses:
--------------------------------------+------------------------------

Comment (by wojtekn):

 @danielbachhuber I reproduced the issue with PHP and MariaDB installed by
 homebrew:
 - PHP 8.0.26
 - mariadb 10.10.2
 - imagick 3.7.0 with ImageMagick 7.1.0-57 (Beta) Q16-HDRI aarch64 20701

 Now when I run `wp media import white-150-square.jpeg --title="My imported
 small attachment"` I get two files in the `wp-content/uploads` directory:

 - white-150-square-150x150.jpeg
 - white-150-square.jpeg

 When I apply your patch, I get only one file. It looks like it fixes the
 issue.

 I'm still unsure for which environment setup this issue pops out, but it
 seems that with your fix, we may have consistent behavior across
 environments.

-- 
Ticket URL: <https://core.trac.wordpress.org/ticket/57370#comment:8>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform


More information about the wp-trac mailing list