[wp-trac] [WordPress Trac] #48520: Remove parsing of readme.txt files from `validate_plugin_requirements()`
WordPress Trac
noreply at wordpress.org
Tue Jun 8 10:16:00 UTC 2021
#48520: Remove parsing of readme.txt files from `validate_plugin_requirements()`
-------------------------------------------------+-------------------------
Reporter: afragen | Owner: afragen
Type: defect (bug) | Status: closed
Priority: normal | Milestone: 5.8
Component: Upgrade/Install | Version:
Severity: normal | Resolution: fixed
Keywords: dev-feedback has-patch needs-docs | Focuses:
needs-codex | administration
-------------------------------------------------+-------------------------
Changes (by SergeyBiryukov):
* status: assigned => closed
* resolution: => fixed
Comment:
In [changeset:"51092" 51092]:
{{{
#!CommitTicketReference repository="" revision="51092"
Upgrade/Install: Remove parsing of `readme.txt` files for plugin or theme
requirements.
This affects:
* `validate_plugin_requirements()`
* `validate_theme_requirements()`
Historically, the `Requires PHP` header was introduced in #meta2952 for
the Plugin Directory first, so at the time it made sense to have it
defined in the same place as `Requires at least`, which only existed in
`readme.txt`.
Since parsing of PHP and WordPress requirements was later added to
WordPress core, the core should retrieve all the necessary data from the
main plugin or theme file and not from `readme.txt`, which only contains
the data meant for the Plugin or Theme Directory.
The recommended place for `Requires PHP` and `Requires at least` headers
is as follows:
* The plugin's main PHP file
* The theme's `style.css` file
The place for the `Tested up to` header remains in `readme.txt` for the
time being, as it's not used by WordPress core.
Follow-up to [44978], [45546], [47573], [47574], [meta5841], [meta9050].
Props afragen, Otto42, joyously, williampatton, audrasjb.
Fixes #48520. See #48515, #meta2952, #meta4514, #meta4621.
}}}
--
Ticket URL: <https://core.trac.wordpress.org/ticket/48520#comment:18>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform
More information about the wp-trac
mailing list