[wp-trac] [WordPress Trac] #11639: In core upgrader, replace the hard-coded required PHP/MySQL versions
WordPress Trac
wp-trac at lists.automattic.com
Wed Dec 30 00:02:44 UTC 2009
#11639: In core upgrader, replace the hard-coded required PHP/MySQL versions
-----------------------------+----------------------------------------------
Reporter: nacin | Owner:
Type: enhancement | Status: new
Priority: normal | Milestone: 3.0
Component: Upgrade/Install | Version: 2.9
Severity: normal | Keywords: has-patch needs-testing
-----------------------------+----------------------------------------------
Comment(by nacin):
Replying to [comment:3 miqrogroove]:
> #11666 Added a bunch of duplicated code. I was surprised this wasn't
already centralized. So, can this ticket be expanded to combine update-
core.php and upgrade.php where appropriate?
Unfortunately, no. We could standardize between upgrade.php and
install.php, but update-core.php is copied by an old installation from a
new installation. So a blog running 2.7 copies over the 2.9 update-
core.php file, which then installs 2.9 over the 2.7 files. This patch
would cause us to also copy over version.php from the incoming package so
we can ascertain new requirements.
Looking at upgrade.php and install.php, there really isn't much to dry up.
The strings are different and it looks like the logic is handled a bit
differently. At most, we could add a function to update-core.php, and
upgrade.php and install.php could include it, but I don't see the point.
I do like the new strings from upgrade.php for use in update-core.php,
though, and I may suggest we copy them over. Of course, since the file is
being copied over, these strings are only future proof when used in
update-core.php, so a blog running 2.9 (or 2.9.1 if we change it) will
have them, but a blog running less than 2.9 and upgrading won't have them.
At least by 3.0 we won't be hard-coding the requirements anywhere.
--
Ticket URL: <http://core.trac.wordpress.org/ticket/11639#comment:4>
WordPress Trac <http://core.trac.wordpress.org/>
WordPress blogging software
More information about the wp-trac
mailing list