Problem/Motivation
there are a number of deprecated code issues relative to php version 8.4
Steps to reproduce
I ran php -l on this module with php 8.4 and got these deprecation issues:
Deprecated: Non-canonical cast (integer) is deprecated, use the (int) cast instead in ./contrib/pantheon_advanced_page_cache/tests/behat/helper_classes/AgeTracker.php on line 80
Deprecated: Non-canonical cast (integer) is deprecated, use the (int) cast instead in ./contrib/pantheon_advanced_page_cache/tests/behat/helper_classes/AgeTracker.php on line 80
Deprecated: Non-canonical cast (integer) is deprecated, use the (int) cast instead in ./contrib/pantheon_advanced_page_cache/tests/behat/helper_classes/AgeTracker.php on line 94
Deprecated: Non-canonical cast (integer) is deprecated, use the (int) cast instead in ./contrib/pantheon_advanced_page_cache/tests/behat/helper_classes/AgeTracker.php on line 94
Proposed resolution
each error indicates how to fix it
Remaining tasks
User interface changes
API changes
Data model changes
| Comment | File | Size | Author |
|---|---|---|---|
| #13 | side_by_side_Diff.png | 393.74 KB | will_frank |
| #13 | pantheon_advanced_page_cache_yours.patch | 1.16 KB | will_frank |
| #13 | pantheon_advanced_page_cache_mine.patch | 1.22 KB | will_frank |
Issue fork pantheon_advanced_page_cache-3564796
Show commands
Start within a Git clone of the project using the version control instructions.
Or, if you do not have SSH keys set up on git.drupalcode.org:
- 3564796-php8.4-fix
compare
- 3564796php8.4-support
changes, plain diff MR !15 /
changes, plain diff MR !16
- 3564796-php8.4-support
compare
Comments
Comment #2
yusuf_khan commentedworking on it
Comment #6
yusuf_khan commentedhttps://git.drupalcode.org/issue/pantheon_advanced_page_cache-3564796/-/... - @maintainer please review my commit im not sure from which branch to create a MR
Comment #9
yusuf_khan commented@will_frank
please review my commit im not sure from which branch to create a MR
Comment #10
will_frank commented@yusuf_khan when I tried to apply the diff patch from merge request !16 it didn't work.
Perhaps this is due to the branch used to create the MR as you mentioned.
Comment #11
will_frank commented@yusuf_khan when I tried to manually apply the changes in the diff from request !16 then
the deprecation errors no longer appeared when I ran php -l on this module with php 8.4.
So if the problem with the diff can be addressed these changes should work.
Comment #12
yusuf_khan commentedThanks for testing, @will_frank.
When I try to create a MR and compare it with the 32x branch, I see other unrelated commits included as well, so I’m not sure which branch to base the MR on to keep it clean.
Do you have a suggestion for which branch I should use as the base so the diff applies correctly or better maintainer can help us on this?
Comment #13
will_frank commented@yusuf_khan I created a patch of the same changes for my code base which does apply correctly.
I've attached that patch file (pantheon_advanced_page_cache_mine.patch) as well as the patch from
your mr (pantheon_advanced_page_cache_yours.patch) and finally a side-by-side visual diff of the two
patches. I hope this helps. I've already said that the version of this module I'm using is Pantheon Advanced Page Cache 2.3.4
but I don't have any insight on which branch to use.