[wp-hackers] Upgrade sanity checks

Computer Guru computerguru at neosmart.net
Thu Feb 28 16:03:36 GMT 2008


Both vBulletin and Gallery2 have this feature, and I know that's been
a great help there.

+1

On 2/27/08, Otto <otto at ottodestruct.com> wrote:
> Whenever an upgrade comes out, one of the things that we get a lot of
>  on the support forums is failed upgrades. The main reasons for these
>  failures are:
>
>  1. Database is setup without correct update permissions, so changes to
>  table structures fail and upgrade.php isn't smart enough to detect it.
>
>  2. Users fail to upload all the files to their site, and so unexpected
>  errors occur. Usually this is the result of some kind of FTP issue
>  where they simply fail to overwrite all the files (this happens so
>  often that we always recommend deleting the old version before
>  uploading the new one), occasionally it's simple user error.
>
>  Now, I've seen a trac ticket for case #1 before (and that can be
>  solved by better error handling in upgrade.php), so I was thinking
>  about case #2. Is it possible for the upgrade.php file to perform a
>  sanity check, and make sure that all the WordPress files are present
>  and correct?
>
>  One way would be to have it load some other file which is a list of
>  all the WordPress files, then check (and potentially hash) them all to
>  ensure that they are unchanged. Every time a new release occurred,
>  that file would need to be generated as part of the release process.
>  Of course, you would want a failure to not *stop* the upgrade, but to
>  get confirmation. The best user experience would be to put up a
>  warning message saying "These WordPress files don't appear to be the
>  correct versions: (list of files here). Proceed with upgrade anyway?
>  WARNING: Proceeding may cause unexpected results! Do not proceed
>  without knowing what you're doing. (Proceed / For the love of god
>  stop!)"
>
>  Just an idea. Bounce it around.
>
>
>  -Otto
>  _______________________________________________
>  wp-hackers mailing list
>  wp-hackers at lists.automattic.com
>  http://lists.automattic.com/mailman/listinfo/wp-hackers
>


-- 
Computer Guru
Director,
NeoSmart Technologies
http://neosmart.net/blog/


More information about the wp-hackers mailing list