Make WordPress Core

Opened 13 months ago

Closed 9 months ago

Last modified 9 months ago

#57939 closed defect (bug) (fixed)

Improved format of plugin upgrade notice

Reported by: afragen's profile afragen Owned by: audrasjb's profile audrasjb
Milestone: 6.3 Priority: normal
Severity: normal Version: 5.5
Component: Upgrade/Install Keywords: has-patch has-testing-info commit
Focuses: administration Cc:

Description

Since the $auto_upgrade_notice has been added to the update-core.php table listing if an $upgrade_notice is present by virtue of the readme.txt containing data in the == Upgrade Notice == section this text will appear in between the compatibility information and the auto update information. This provides a less consistent appearance.

I propose moving the upgrade notice information after the auto update information.

Related: #34986

Attachments (3)

post-PR-view.png (77.0 KB) - added by afragen 13 months ago.
pre-PR-view.png (84.5 KB) - added by afragen 13 months ago.
57939-force-upgrade-notice.zip (843 bytes) - added by costdev 9 months ago.
Test plugin: Adds an $upgrade_notice key for all plugin updates.

Download all attachments as: .zip

Change History (16)

This ticket was mentioned in PR #4242 on WordPress/wordpress-develop by @afragen.


13 months ago
#1

Since the $auto_upgrade_notice has been added to the update-core.php table listing if an $upgrade_notice is present by virtue of the readme.txt containing data in the == Upgrade Notice == section this text will appear in between the compatibility information and the auto update information. This provides a less consistent appearance

Trac ticket: https://core.trac.wordpress.org/ticket/57939

@afragen
13 months ago

#2 @afragen
13 months ago

  • Type changed from enhancement to defect (bug)
  • Version set to 5.5

#3 @afragen
13 months ago

  • Summary changed from Improved location of plugin upgrade notice to Improved format of plugin upgrade notice

#4 @costdev
13 months ago

  • Milestone changed from Awaiting Review to 6.3

This ticket was mentioned in Slack in #core-upgrade-install by afragen. View the logs.


11 months ago

This ticket was mentioned in Slack in #core-upgrade-install by costdev. View the logs.


9 months ago

#7 @costdev
9 months ago

  • Keywords needs-testing needs-testing-info added

Hey @afragen, could you add some testing instructions so this can be picked up by the Test Team? Thanks!

#8 @costdev
9 months ago

  • Keywords has-testing-info added; needs-testing-info removed

Testing Instructions

These steps define how to test the enhancement, and indicates the expected behavior or results. Provided by Andy in Slack DM.

Steps to Test

  1. Install and activate the test plugin.
  2. Navigate to Plugins > Installed Plugins and click Enable auto-updates beside one of your existing plugins.
  3. Decrease that plugin's Version header in its main file (e.g. plugins/akismet/akismet.php) so that an update shows.
  4. Navigate to Dashboard > Updates and examine the plugin's row in the update table.
  5. Apply the PR.
  6. Refresh the Dashboard > Updates screen and examine the plugin's row again.

Expected Results

  • ✅ Before the PR: The upgrade notice should appear between the compatibility information and the auto-update information.
  • ✅ After the PR: The upgrade notice should appear after the auto-update information.
Last edited 9 months ago by costdev (previous) (diff)

@costdev
9 months ago

Test plugin: Adds an $upgrade_notice key for all plugin updates.

#9 @zunaid321
9 months ago

Test Report

This report validates that the indicated patch addresses the issue.

Patch tested: https://patch-diff.githubusercontent.com/raw/WordPress/wordpress-develop/pull/4242.diff

Environment

  • OS: Windows 11 (22H2)
  • Web Server: nginx/1.23.4
  • PHP: 7.4.33
  • WordPress: 6.3-alpha-55505-src
  • Browser: Chrome Version 114.0.5735.110 (Official Build) (64-bit)
  • Theme: Twenty Twenty-Three

Before Applying The Patch

  • Followed the instructions of @costdev
  • The upgrade notice appeared between the compatibility information and the auto-update information.

After Applying The Patch

  • Followed the same instructions
  • ✅ The upgrade notice appeared after the auto-update information.

Plugins Used

Screenshots

#10 @costdev
9 months ago

  • Keywords commit added; needs-testing removed

Thanks for testing @zunaid321!

Test Report

This report validates that the indicated patch addresses the issue.

Patch tested: https://patch-diff.githubusercontent.com/raw/WordPress/wordpress-develop/pull/4242.diff

Environment

  • WordPress: 6.3-alpha-55505
  • PHP: 7.4.33
  • Server: Apache/2.4.56 (Ubuntu)
  • Database: mysqli (Server: 5.7.41-0ubuntu0.18.04.1 / Client: mysqlnd 7.4.33)
  • Browser: Chrome 114.0.0.0 (Windows 10/11)
  • Theme: Twenty Twenty-Three 1.1
  • MU-Plugins: None activated.
  • Plugins:
    • Add an upgrade notice to all plugin updates. 1.0.0

Actual Results

  • ✅ Before the PR: The upgrade notice appeared between the compatibility information and the auto-update information.
  • ✅ After the PR: The upgrade notice appeared after the auto-update information.

Additional Notes

  • This has two confirming test reports now. Removing needs-testing.
  • This is a straightforward patch and change. Adding for commit consideration.

#11 @audrasjb
9 months ago

  • Owner set to audrasjb
  • Status changed from new to accepted

#12 @audrasjb
9 months ago

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

In 56001:

Upgrade/Install: Move location of $upgrade_notice for better consistency.

Since the $auto_upgrade_notice has been added to the update-core.php table listing if an $upgrade_notice is present by virtue of the readme.txt
containing data in the == Upgrade Notice == section, this text will appear in between the compatibility information and the auto update information.

This changeset provides a more consistent appearance in the interface.

Props afragen, costdev, zunaid321.
Fixes #57939.

Note: See TracTickets for help on using tickets.