[wp-trac] [WordPress Trac] #53455: WP:5.6 is Generating Zero-Sized files of previously deleted Media

WordPress Trac noreply at wordpress.org
Tue Jun 22 05:48:57 UTC 2021


#53455: WP:5.6 is Generating Zero-Sized files of previously deleted Media
-------------------------------------------+------------------------------
 Reporter:  HisKingdomProphecy             |       Owner:  (none)
     Type:  defect (bug)                   |      Status:  closed
 Priority:  normal                         |   Milestone:  Awaiting Review
Component:  Media                          |     Version:  5.6
 Severity:  normal                         |  Resolution:  invalid
 Keywords:  needs-patch reporter-feedback  |     Focuses:  administration
-------------------------------------------+------------------------------
Changes (by HisKingdomProphecy):

 * status:  new => closed
 * resolution:   => invalid


Comment:

 @SergeyBiryukov

 Thank you for your response.

 The testing you suggested showed up nothing.

 However, after analysis and other forms of testing, I have found (suspect)
 that preexisting `class "wp-image-____"` handling procedures in code in
 the Cloudinary plugin cause the generation of there zero-sized files, when
 the image asset is removed from the site/uploads/ and the Cloudinary/DB
 but that link is still live in the WP wp-postmeta table.

 Thus, when we updated to WP:5.6 on December 8, 2020, the preexisting
 Cloudinary issue came to light and since that update, the plugin and WP
 have generated blank files with the names of the 'missing' assets' and
 drop them into the current /uploads/ dir.

 AS a user, the root of the problem is that for me to modify the URL of any
 uploaded media asset, I need to first remove the `class "wp-image-_____"`
 link.

 That allows me to change out linked asset url.  It also allows me to stack
 images with no space between them, as the `class "wp-image-____"` seems to
 have undefined and unknown WP css attached to it, which shows up on
 phones, where a line of images of 6, are displayed in rows of 3&3.

 So, with a `class "wp-image-____"` reference still in the DB wp-postmeta
 table, but not in any post, WP & Cloudinary solve the issue by generating
 - again and again - the necessary media asset, as a zero-sized file.

 Since I use Cloudinary handle all of the images we display on our site, I
 have passed this to them to figure out.

 Images and mdeia which we use once in a post use default settings and all
 contain a `class "wp-image-____"` link... and have no issues.

 It is only those who's `class "wp-image-____"` link  has been removed to
 add SEO to the file name or update an image url for some reason, that have
 this issue, and where that original asset url no longer related to an
 asset on our DB or Cloudinary's DB.

 Sorry if this is a bit long winded, but this seems to be the root issue
 which Cloudinary need to work out and resolve.

 If you want any further information on this, please just ask.  Else, I
 will consider this issue closed as others are - I hope - working to
 resolve it.

 Regards and thanks.
 Angus

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


More information about the wp-trac mailing list