WordPress.org

Make WordPress Core

Opened 5 years ago

Last modified 6 months ago

#10884 accepted defect (bug)

Available plugin update count disappears after updating plugin

Reported by: sirzooro Owned by: dd32
Milestone: Future Release Priority: normal
Severity: normal Version: 2.8.4
Component: Upgrade/Install Keywords: has-patch dev-feedback
Focuses: Cc:

Description

When there are any available plugin updates, WP displays number of them next to "Plugins" item in menu. However when you have more than one update available and update one plugin, it disappears.

Steps to reproduce:

  • make sure you have more than one plugin with update available (WP should count of them in menu);
  • go to the Plugin page and click on Autoupdate link for plugin;
  • when update page will load completely, click on provided link to return to plugin list.

Expected result: WP displays new number of available updates next to Plugins menu.
Actual result: nothing is displayed.

Note: I tested this for inactive plugins only.

Attachments (1)

10884.diff (1.6 KB) - added by dd32 4 years ago.

Download all attachments as: .zip

Change History (5)

comment:1 @dd325 years ago

  • Component changed from General to Upgrade/Install
  • Owner set to dd32
  • Status changed from new to accepted

This sounds like an issue that has been run into before, Related to the fact that on some hosts, an update-check cannot be executed within the timeframe allowed on the new page load..

The reason why it happens that the update check is re-performed, is due to that the transients cannot be modified, without increasing the time the transient can live. If theres 60seconds left on the update ttransient, and ts modified, it'll keep that (potentially stale) transient for another 12 hours.. I dont believe theres currently a way to determine how much time is left for a given transient.

I'm going to take a closer look at this time permitting.

comment:2 @azaozz5 years ago

  • Milestone changed from 2.9 to Future Release

No patch.

@dd324 years ago

comment:3 @dd324 years ago

  • Keywords has-patch dev-feedback added; needs-patch removed

Attached patch takes care of this.

The question is, Is the extra API request worth it.

The downside of this is that the end of the update page may be delayed up to 3 seconds from displaying depending on the server's willingness to flush the data out to the client or not. It'll also cause a double API request if they visit the update-core page straight away (As I think it makes a request regardless)

comment:4 @chriscct76 months ago

@dd32 can you still reliably reproduce this on 4.0?

Note: See TracTickets for help on using tickets.