[wp-trac] [WordPress Trac] #60398: WordPress 6.4.3 MacOS Compressed Zip plugin archives "Incompatible Archive" on upload

WordPress Trac noreply at wordpress.org
Thu Feb 1 18:23:28 UTC 2024


#60398: WordPress 6.4.3 MacOS Compressed Zip plugin archives "Incompatible Archive"
on upload
----------------------------------------------------+---------------------
 Reporter:  Endymion00                              |       Owner:  (none)
     Type:  defect (bug)                            |      Status:  new
 Priority:  normal                                  |   Milestone:  6.4.4
Component:  Upload                                  |     Version:  6.4.3
 Severity:  normal                                  |  Resolution:
 Keywords:  needs-testing has-patch has-unit-tests  |     Focuses:
----------------------------------------------------+---------------------

Comment (by costdev):

 > @tnolte Plugin & theme developers should not be using daily driver
 developer machines to package plugins. In this day in age with freely
 available CI/CD process that can do this in more protected environments

 There are many developers that will write a quick, bespoke, and multi-file
 plugin for a client site and need to upload it, where CI/CD flows are
 overkill. It's also a common (and unfortunate) occurrence that for some
 small jobs, developers aren't given FTP access for some work and only have
 the ability to upload via the Dashboard.

 -----

 **To fix or not to fix**
 ''there is no question'' 😉

 Fix.

 This change had no intention of causing disruption with valid ZIP files,
 so this is a bug by definition. While we could theoretically decide to
 keep it and say "tough", the WordPress project has a commitment to
 backward compatibility. With that in mind, the action most in-line with
 our commitment is to do what we're doing: Fix the bug so that previously
 valid ZIPs remain valid.

 `unzip_file()` is a good reference for how we should handle this:
 - uses `ZipArchive` if it's available and hasn't been disabled by
 `add_filter( 'unzip_file_use_ziparchive', '__return_false' );`
 - `ZipArchive` checks for consistency in the ZIP (`CHECKCONS`)
 - If `ZipArchive` can't open the file, `unzip_file()` will fall back to
 `PclZip`.

 This fallback is what 6.4.3 is missing, and this ticket's PR adds it.
 -----
 **When to release**
 A working fix is obviously a great step ([https://github.com/WordPress
 /wordpress-develop/pull/5996 please test]!), and one of the next steps
 will be deciding when to get it out there.

 This issue, like all issues, has caused disruption. However, sites have
 not gone down, files have not been deleted, and themes aren't broken.
 There is a limited number of affected developers, who can repackage their
 plugins using an alternate method. There is a limited number of affected
 users, and several alternatives have been mentioned during this
 discussion. While the workarounds aren't literal one-click solutions,
 they're available whereas other issues may have no workaround.

 The project's processes include us measuring the reach and impact of each
 bug to package fixes appropriately. Otherwise, we'd be releasing a new
 WordPress version for every individual fix and pushing to millions of
 sites and servers 3-4 times a day. That's a lot of room for something to
 go wrong, and even if it always went right, can you imagine the update
 email spam? 💀

 We will be continuing to monitor other issues and fixes to determine how
 we can best package these for release as soon as possible.

 -----
 **Until then, what do I do if I have this issue?**

 - Users/Site owners/Site developers: Download, install and activate
 [https://core.trac.wordpress.org/raw-attachment/ticket/60398/force-
 pclzip-0.1.zip the workaround plugin] (Safari users: Option+Click the
 link, or disable [https://core.trac.wordpress.org/ticket/60398#comment:41
 this setting] before downloading the plugin)
 - Plugin/Theme authors: If your non-Safari users are reporting that your
 ZIP isn't uploading, repackage your plugin or theme using a commandline
 tool rather than Finder/Nautilus/Gnome/etc. For your Safari users, direct
 them to the point above.
 - QA: Test [https://github.com/WordPress/wordpress-develop/pull/5996 the
 fix] so we can be extra confident that the issue is fully resolved.
 - Everyone: Help get the word out there about this work being well
 underway and the available workarounds.

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


More information about the wp-trac mailing list