WordPress / WordPress/Requests
More classes planned to be made final
Nobody has claimed this yet.
- Dominant language
- PHP
- Stars
- 3.6k
- Forks
- 500
- Avg merge
- 2d 21h
- Merged PRs (30d)
- 5
Description
In the next major version of Requests (v3.x), we plan on making more classes final, to simplify the process of keeping in line with the accelerating pace of PHP changes without always incurring the overhead of a BC break.
The v3.x release is still far away on the horizon, but we'd like to get the discussion started as early as possible on this to give affected people a heads-up and hopefully gather more feedback before we pull the trigger on this.
If you can provide any feedback on why or why not some of these classes should be made final, please add a comment on this issue. We're happy to consider valid use cases and make sure we can respect any reasonable extension scenarios.
The following classes are UNDER CONSIDERATION to be made final
We think these are not currently being extended, and making them final will simplify the long-term maintenance work on this package.
| Make final? | Class name in v2.x | Class name in v1.x | Notes |
|---|---|---|---|
| no | WpOrg\Requests\Requests |
Requests |
Keep extensible as last-resort fallback |
| yes | WpOrg\Requests\Cookie |
Requests_Cookie |
Direct coupling in WpOrg\Requests\Cookie\Jar |
| yes | WpOrg\Requests\IdnaEncoder |
Requests_IDNAEncoder |
Direct coupling in WpOrg\Requests\Requests & WpOrg\Requests\Cookie |
| yes | WpOrg\Requests\Iri |
Requests_IRI |
Direct coupling in WpOrg\Requests\Requests & WpOrg\Requests\Cookie\Jar & WpOrg\Requests\Session |
| yes | WpOrg\Requests\Cookie\Jar |
Requests_Cookie_Jar |
Direct coupling in WpOrg\Requests\Requests & WpOrg\Requests\Response & WpOrg\Requests\Session |
| yes | WpOrg\Requests\Response\Headers |
Requests_Response_Headers |
Direct coupling in WpOrg\Requests\Response |
The following classes will NOT be made final
These classes are known to be already extended at this time and will remain as-is for that reason.
| Class name in v2.x | Class name in v1.x |
|---|---|
WpOrg\Requests\Exception |
Requests_Exception |
WpOrg\Requests\Hooks |
Requests_Hook |
WpOrg\Requests\Response |
Requests_Response |
WpOrg\Requests\Session |
Requests_Session |
WpOrg\Requests\Auth\Basic |
Requests_Auth_Basic |
WpOrg\Requests\Utility\CaseInsensitiveDictionary |
Requests_Utility_CaseInsensitiveDictionary |
WpOrg\Requests\Exception\Http |
Requests_Exception_HTTP |
WpOrg\Requests\Exception\Transport |
Requests_Exception_Transport |
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Review the listed WpOrg\Requests classes and the extension rationale in this issue before proposing feedback. The issue does not identify files, tests, or an implementation target; completion depends on a maintainer decision about which classes should become final.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- php
- Domain
- backend
- Issue type
- Refactor
- Difficulty
- 5/5
- Estimated time
- Over a week
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 20/100