WordPress.org

Make WordPress Core

Opened 22 months ago

Last modified 13 months ago

#43077 new defect (bug)

Misleading error when updating plugins

Reported by: SGURYGF Owned by:
Milestone: Awaiting Review Priority: normal
Severity: normal Version: 4.9.1
Component: Plugins Keywords:
Focuses: administration Cc:
PR Number:

Description

Hi,

I am in /wp-admin/plugins.php

A plugin has a new update and I click "Update now". After a few seconds I get "Update Failed: Could not copy file."

However, when I refresh the page and I see that the plugin was updated.

After a few tests I realise that if there are Core Translation Updates and they fail(for example due to bad filesystem permissions), you will get the error mentioned above even though the plugin was successfully updated.

I would like to comment on two things:

a) The translations shouldn't get updated with any plugin update. I might NOT want to update the translations. By doing it in the background without asking me that's bad.

b) The error message shown is irrelevant to the plugin update and might cause confusion to some admins who might try to reinstall manually a plugin or do any other changes which might eventually end up breaking a site for nothing.

Thanks in advance for your time.

Change History (4)

#2 @SergeyBiryukov
22 months ago

  • Component changed from General to Plugins
  • Focuses administration added

#3 @galbaras
14 months ago

I've just had this with an admin JavaScript file unrelated to language translation in Contact Form 7. A subsequent update succeeded without a hitch and without making any changes in-between, ruling out environmental issues, like permissions.

Could this be related to timing?

Either way, WordPress is not listing the update, despite the failure, possibly because the main file contains the latest version, which is insufficient proof, unfortunately.

When an update failure occurs, WordPress should either roll back to the previous version or, at least, keep the outstanding update signals active until it is applied to completion.

#4 @galbaras
13 months ago

For better string matching of this ticket, the current (4.9.8) error message is "An error occurred while updating" and then "All updates have been completed."

Also, should this not be under "Upgrade/install", instead of "Plugins"?

Note: See TracTickets for help on using tickets.