Make WordPress Core

Opened 9 years ago

Closed 9 years ago

#31978 closed enhancement (fixed)

Shiny updates: trigger "update success" message after unlocking, not before

Reported by: davidanderson's profile DavidAnderson Owned by: jorbin's profile jorbin
Milestone: 4.2 Priority: normal
Severity: normal Version: 4.2
Component: Upgrade/Install Keywords:
Focuses: ui, javascript, administration Cc:

Description

In change-set https://core.trac.wordpress.org/changeset/32061 , an event was triggered upon completion of shiny updates.

This, I thought, solved the previous need for polling I had, in #31819. Further testing has revealed this to not be the case.

In fact, the real event I was trying to detect was not so much "update completed", as "lock released because updated completed".

Changeset 32061 added the trigger *before* releasing the lock (the lock release was immediately after). The attached patch moves the trigger to immediately *after* the lock release. So now, users of the trigger can know that the queue is unlocked, and respond accordingly.

(Alternatively, I suppose a second trigger could be added, so that both are covered. I'm not sure there's a use-case for this, though - I know there is for what I am trying to do, as it's for a live/popular plugin).

Attachments (1)

trigger-update-event-later.patch (527 bytes) - added by DavidAnderson 9 years ago.
Move "update complete" trigger to after the queue has been unlocked

Download all attachments as: .zip

Change History (4)

@DavidAnderson
9 years ago

Move "update complete" trigger to after the queue has been unlocked

#1 @jorbin
9 years ago

  • Milestone changed from Awaiting Review to 4.2
  • Owner set to jorbin
  • Status changed from new to assigned
  • Version changed from 4.1.1 to trunk

This ticket was mentioned in Slack in #core by drew. View the logs.


9 years ago

#3 @jorbin
9 years ago

  • Resolution set to fixed
  • Status changed from assigned to closed

In 32133:

Move wp-plugin-update-success event to after lock is released

Fixes #31978
See #31819
Props DavidAnderson

Note: See TracTickets for help on using tickets.