-
Notifications
You must be signed in to change notification settings - Fork 9.4k
Open
Labels
Issue: ready for confirmationTriage: Dev.ExperienceIssue related to Developer Experience and needs help with Triage to Confirm or Reject itIssue related to Developer Experience and needs help with Triage to Confirm or Reject it
Description
Summary
As discussed in issue #39362, we should remove legacy workarounds for PHP bugs that applied only to unsupported PHP versions. This follow-up was suggested by @ihor-sviziev in this comment
— “Maybe worth fixing them as well.”
Reference search for candidates: GitHub code search.
Scope
- Identify code that references historical PHP engine bugs (e.g., links to bugs.php.net, comments like “PHP bug …”, conditional branches for old PHP versions, polyfills/workarounds that targeted those bugs).
- Remove such workarounds only if they are relevant exclusively to PHP versions outside Magento’s currently supported matrix.
- Keep behavior and public APIs intact for supported PHP versions.
Out of scope
- Removing fixes that are still required for supported PHP versions.
- Broad refactors unrelated to obsolete PHP bug workarounds.
Examples
Class lib/internal/Magento/Framework/Session/SaveHandler/Native.php was only created to fix the bug https://bugs.php.net/bug.php?id=71187
And this is actual for PHP Version 7.0.1
Proposed solution
- Use the search query above to compile a list of candidate classes/files.
- For each candidate:
- Verify the original PHP bug and affected versions.
- Confirm that the affected versions are not supported by current Magento releases.
- Remove the workaround path or entire helper/polyfill if it existed solely for that bug.
- Add/adjust unit and integration tests to cover the code paths that remain.
Release note
No response
Triage and priority
- Severity: S0 - Affects critical data or functionality and leaves users without workaround.
- Severity: S1 - Affects critical data or functionality and forces users to employ a workaround.
- Severity: S2 - Affects non-critical data or functionality and forces users to employ a workaround.
- Severity: S3 - Affects non-critical data or functionality and does not force users to employ a workaround.
- Severity: S4 - Affects aesthetics, professional look and feel, “quality” or “usability”.
Metadata
Metadata
Assignees
Labels
Issue: ready for confirmationTriage: Dev.ExperienceIssue related to Developer Experience and needs help with Triage to Confirm or Reject itIssue related to Developer Experience and needs help with Triage to Confirm or Reject it