[wp-trac] [WordPress Trac] #34878: Core Auto Updater Needs to be Aware of Manual Updates

WordPress Trac noreply at wordpress.org
Sun Dec 6 20:15:58 UTC 2015


#34878: Core Auto Updater Needs to be Aware of Manual Updates
-----------------------------+----------------------------
 Reporter:  aaroncampbell    |      Owner:
     Type:  defect (bug)     |     Status:  new
 Priority:  normal           |  Milestone:  Future Release
Component:  Upgrade/Install  |    Version:
 Severity:  normal           |   Keywords:
  Focuses:                   |
-----------------------------+----------------------------
 Some of the "critical failures" that we get for automatic core updates of
 major releases are actually a race condition between a manual update and
 an auto update.

 The auto updater uses an option called `auto_updater.lock` to avoid race
 conditions with itself, but that needs to be extended to account for
 manual updates as well.

 Example:
 - A user clicks upgrade and a manual upgrade starts
 - WordPress checks and sees that an update is needed and starts and auto
 update
 - The zip is downloaded and extracted by the manual upgrade and it begins
 to copy files
 - The zip is downloaded and extracted to the same location by the auto-
 update upgrade and it begins to copy files
 - The manual update finishes and removes the files it was copying from
 - The auto-updater is still trying to copy files, but they no longer exist
 because the manual updater removed them.

 This can happen in either order (manual update can fail because the auto
 updater finished first).

 These two upgrade processes need to be aware of each other.

--
Ticket URL: <https://core.trac.wordpress.org/ticket/34878>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform


More information about the wp-trac mailing list