Skip to content
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

Add PHP 8.4 to the CI and fix implicit nullable types #259

Closed
wants to merge 2 commits into from

Conversation

nicolas-grekas
Copy link

Cherry-picking from #258

Fixes all issues that emits a deprecation notice on PHP 8.4.

See:
 - [RFC](https://wiki.php.net/rfc/deprecate-implicitly-nullable-types)
 - [PHP 8.4: Implicitly nullable parameter declarations deprecated](https://php.watch/versions/8.4/implicitly-marking-parameter-type-nullable-deprecated)
@nicolas-grekas
Copy link
Author

nicolas-grekas commented Mar 19, 2024

(I'm now looking at why the job fails on 8.4)

@nicolas-grekas
Copy link
Author

Now green on PHP 8.4. All it needs is the latest version of phpunit (not tagged yet)

Copy link
Member

@SimonFrings SimonFrings left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@nicolas-grekas Thanks for opening this pull request 👍

Seems like a reasonable change to me. I originally said that it makes sense to wait for the other additions and changes for PHP 8.4, but after the conversation with @Seldaek in #258, I also agree that it makes sense to create compatibility with the upcoming PHP version now (especially to avoid any deprecation warnings).

@clue looked into supporting the latest PHPUnit versions as well, but we'll probably address this in a later pull request

Also big thank you to @Ayesh for opening #258 which contained most of the changes in here 👍

@Seldaek
Copy link

Seldaek commented Mar 26, 2024

Great, thanks for listening to feedback :)

@andypost
Copy link

andypost commented May 8, 2024

Is there any expected date for new release compatible with fixed nullable types?
PHPstan depends on it and it will be helpful to prevent this deprecations

@SimonFrings
Copy link
Member

I opened a new pull request in #260 for this. The ongoing development in PHP 8.4 is currently breaking our test suite (changed stack trace -> failing .phpt test files), which will be visible in here once we'd rerun the currently green test suite (last executed on 2024-03-19).

I created a new proposal, which follows the original pull request from @Ayesh in #258. I tried to reopen the old PR, but couldn't do so as the created fork was already removed. Once #260 is approved and merged, it will automatically close this PR here as well.

Sorry for the back and forth, but I think we've come to a viable solution now. Thanks for everybody who contributed to the discussion 👍

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants