-
Notifications
You must be signed in to change notification settings - Fork 30
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
PHP 8.2 support #26
PHP 8.2 support #26
Conversation
14aae3a
to
46d70e5
Compare
What's the practical reason for increasing PHP requirements instead of using attributes? |
Hi @SharkyKZ thanks for your question, the practical reason is so that this package works with PHP 8.2 out of the box, which it currently does not. As the README states there are three major versions of this package, all targeting specific PHP versions. This follows semantic versioning, where breaking changes get a new major. Lines 30 to 46 in 1601ca7
Attributes are a possibility, I'll let the maintainers decide which approach they would like to take. Looking forward to moving this package forward. |
That is not a practical reason because narrowing PHP version support is not required to support PHP 8.2. It's a change for the sake of change. Of course, it's up to maintainers to decide. But with current code base there is no gain. Even the hard v6 requirement for |
It's not change for the sake of change, out of the box this package is causing errors when running Psalm on PHP 8.2.
Not pulling that updated package in because it's "technically not necessary" is not moving this package forward. |
I think you misunderstood. Supporting v6 is fine but dropping v5.4 was technically unnecessary. Likewise, there was no practical reason to drop PHP 7.3 support when you can simply use |
Hi I don't really want to have too many versions. It's possible to keep the compatibility with 7.3 and upgrade portable-utf8 (to be compatible php8.2) Thanks ! |
I've added PHP 8.2 to the test matrix, and added back in the stability of lowest and stable All test are now passing https://github.com/patrickomeara/php-stemmer/actions/runs/4129148443 |
As a workaround, since this library requires no changes when using "require": {
"voku/portable-utf8": "6.0.12 as 5.4.0"
} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks good to me
@wamania can we merge this and release a new version please? |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks good
This PR updates
voku/portable-utf8
where a string interpolation deprecation has been fixed.It also updates the test files to match the iterator parent return types. This upgrade means that the tests will only run on PHP 8.0 and above, due to
mixed
not being available on earlier versions. However, this matches the official supported versions https://www.php.net/supported-versions.phpI've preemptively updated the README assuming there will be a new major version released.
I've also added a github actions workflow to test PHP 8.0, 8.1 and 8.2 but Actions will need to be turned on for this repo. There may need to be changes to the file after it has been ran. I'm just basing it off other files across public and my private repos.