You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@thrift.apache.org by "sveneld (via GitHub)" <gi...@apache.org> on 2026/05/02 08:24:54 UTC
[PR] THRIFT-5956: Bump minimum PHP version to 8.1 [thrift]
sveneld opened a new pull request, #3435:
URL: https://github.com/apache/thrift/pull/3435
JIRA: https://issues.apache.org/jira/browse/THRIFT-5956
Client: php
## Summary
Drop PHP 7.x and 8.0 from the supported floor. PHP 7.x is fully EOL upstream
(7.0 since 2019, 7.4 since 2022) and 8.0 since 2023. The PHP test suite has
matured enough to make this maintenance simplification safe.
- `composer.json`: require PHP `^8.1`; collapse PHPUnit constraint to `^9.5`
(the only PHPUnit line that runs on PHP 8.1 without dropping the
annotation-style tests we still use); bump phpcs to `^3.10`.
- `lib/php/phpunit.xml`: bump schema URL to 9.5.
- `.github/workflows/build.yml`: drop the `7.1`/`7.2`/`7.3`/`7.4`/`8.0` rows
of the `lib-php` matrix.
- `build/docker/ubuntu-focal/Dockerfile`: install PHP 8.1 from
`ppa:ondrej/php` (focal default is 7.4, below the new floor).
- `build/docker/README.md`: refresh the version table.
- `CHANGES.md`: announce the breaking change under 0.24.0.
Migrating to PHPUnit 10/11 and modernizing the C++ → PHP generator output
(typed properties, native enums, `declare(strict_types=1)`) are intentionally
left to follow-up tickets.
Users still on PHP 7.x or 8.0 can remain on the 0.23.x release series.
## Test plan
- [ ] `lib-php` GitHub Actions matrix passes on PHP 8.1 / 8.2 / 8.3 / 8.4 / 8.5
- [ ] `cross-test` job (pinned at PHP 8.3) passes
- [ ] `build/docker/ubuntu-focal` image builds successfully with the
`ondrej/php` PPA and `php -v` reports `8.1.x`
- [ ] `build/docker/ubuntu-jammy` and `build/docker/ubuntu-noble` images
build unchanged
- [ ] Re-running `compiler/cpp/thrift --gen php:...` for all modes
(`nsglobal`, `inlined`, `validate`, `validate,oop`, `json`,
`classmap,server,rest`) produces output identical to the previous
compiler (generator code is untouched in this PR)
Generated-by: Claude Opus 4.7 (1M context)
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: dev-unsubscribe@thrift.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [PR] THRIFT-5956: Bump minimum PHP version to 8.1 [thrift]
Posted by "sveneld (via GitHub)" <gi...@apache.org>.
sveneld merged PR #3435:
URL: https://github.com/apache/thrift/pull/3435
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: dev-unsubscribe@thrift.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [PR] THRIFT-5956: Bump minimum PHP version to 8.1 [thrift]
Posted by "kpumuk (via GitHub)" <gi...@apache.org>.
kpumuk commented on code in PR #3435:
URL: https://github.com/apache/thrift/pull/3435#discussion_r3177271029
##########
build/docker/ubuntu-focal/Dockerfile:
##########
@@ -235,15 +235,19 @@ RUN apt-get install -y --no-install-recommends \
libnet-ssleay-perl \
libtest-exception-perl
+# PHP via Ondřej Surý PPA (focal default is 7.4 which is below our 8.1 floor)
+RUN add-apt-repository -y ppa:ondrej/php && \
Review Comment:
Note to myself: Ondřej Surý is the maintainer of the PHP packages for Debian and Ubuntu (both the official ones and the ones you are using via the PPA).
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: notifications-unsubscribe@thrift.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [PR] THRIFT-5956: Bump minimum PHP version to 8.1 [thrift]
Posted by "sveneld (via GitHub)" <gi...@apache.org>.
sveneld commented on PR #3435:
URL: https://github.com/apache/thrift/pull/3435#issuecomment-4363548938
@pkvach FYI
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: notifications-unsubscribe@thrift.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [PR] THRIFT-5956: Bump minimum PHP version to 8.1 [thrift]
Posted by "kpumuk (via GitHub)" <gi...@apache.org>.
kpumuk commented on PR #3435:
URL: https://github.com/apache/thrift/pull/3435#issuecomment-4366157829
@sveneld I think it would be a good idea to update README.md in `lib/php`, which is rendered on the website: https://thrift.apache.org/lib/php.html
Specifically, minimum version, maybe mention we raised the minimum version in the breaking changes section.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: notifications-unsubscribe@thrift.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [PR] THRIFT-5956: Bump minimum PHP version to 8.1 [thrift]
Posted by "sveneld (via GitHub)" <gi...@apache.org>.
sveneld commented on PR #3435:
URL: https://github.com/apache/thrift/pull/3435#issuecomment-4366200052
I will update README.md after all planned changes will be completed.
Planned changes:
- Update the PHPUnit version
- Fix issues reported by PHPStan
- Add type hinting
- Update the PSR coding style
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: notifications-unsubscribe@thrift.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org