-
Notifications
You must be signed in to change notification settings - Fork 665
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
CI should fail on PHP deprecated errors and report errors for deprecated implicit float to int precision loss #10958
base: 5.x
Are you sure you want to change the base?
CI should fail on PHP deprecated errors and report errors for deprecated implicit float to int precision loss #10958
Conversation
In my experience you also need to set a proper php.ini in the github action. See e.g. nikic/PHP-Parser@f2e037f |
9784367
to
b20b36d
Compare
@staabm thanks for your comment, saved me some time. Just adding the error_reporting ini value turned out to be sufficient though. Ready to review and merge. |
.github/workflows/windows-ci.yml
Outdated
@@ -54,8 +54,8 @@ jobs: | |||
- name: Set up PHP | |||
uses: shivammathur/setup-php@v2 | |||
with: | |||
php-version: '8.0' | |||
ini-values: zend.assertions=1, assert.exception=1, opcache.enable_cli=1, opcache.jit=function, opcache.jit_buffer_size=512M | |||
php-version: '8.3' |
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.
would actually prefer this lowered to 7.4
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.
Done + also added a CI for PHP 7.4 in linux. There are a couple bugs as seen with the failing tests.
Additionally, there is a bug in delta loading - when running psalm with PHP 7.4 but a phpVersion > 7.4, it won't load delta and psalm reports various incorrect errors (e.g. for get_headers
2nd arg it asks for int, which is wrong in PHP 8)
There are lots of issues related to these in tests, some of which I fixed in pending to be merged PRs e.g. #10813 and #10777
(bc then I can also finish #10771 which fixes part of that issue too)
Could you please go ahead and merge those PRs?
I'll revert the CI to not run with 7.4 and set Windows to 8.0 again in this PR once I hear back from you, so it can be merged already and implement the 7.4 CI in #10771
78c3b17
to
896e115
Compare
Fix #10957
Fix #10950
Fix #10949
Update parts of CI to use PHP 8.3 instead of older PHP versions.