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鈥檒l occasionally send you account related emails.

Already on GitHub? Sign in to your account

chore: improve static analysis, bump min PHP to 7.4, support PHP 8.2 #31

Open
wants to merge 7 commits into
base: main
Choose a base branch
from

Conversation

ramsey
Copy link

@ramsey ramsey commented Dec 15, 2022

Proposed changes

  • Adds a lot of new tooling for static analysis
  • Bumps the minimum PHP version to 7.4
  • Supports PHP 8.1 and 8.2
  • Runs CI builds on PHP versions 7.4 through 8.2

Since this adds parameter types and return types in many places where there were none, this can break BC for applications using this and extending classes or passing the wrong values into methods. As such, I recommend bumping the package's major version when doing the next release (after this is merged).

馃毃 This stands to cause a lot of merge conflicts with #26. I'm not sure how we want to handle that. Which should we merge first?

How to test

  • composer test

Unit Tests

  • This PR has unit tests: updates to the unit tests, as needed
  • This PR does not have unit tests: why?

@Makapashev
Copy link

@ramsey please release PR #26. I think it's more important to add support of federation v2 rather than analytic and support of php 8.1.

@ldiego08
Copy link
Contributor

@ramsey my two cents, #26 should go first given it's been open for a really long time and will get even more delayed if there are merge conflicts. Also, +1 to @Makapashev's comment.

@Aeliot-Tm
Copy link

@ramsey You may add code coverage baseline to control that it is not downgraded with new PRs :)

https://github.com/Aeliot-Tm/phpunit-codecoverage-baseline

@rvanlaak
Copy link

@Aeliot-Tm would you consider such code coverage baseline a blocker for getting this PR in a mergeable state? or could it be handled through a follow-up?

@rvanlaak
Copy link

@ramsey any reason why both PHPStan and Psalm as static code analysis tools are added? Yes they can capture marginally different things, but solely starting with PHPStan with a baseline file might be a more controllable way of adding static analysis (e.g. as all future contributors will also have to work with it)?

@rvanlaak rvanlaak mentioned this pull request May 30, 2023
2 tasks
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.

None yet

5 participants