vobject
vobject copied to clipboard
Type declarations to increase phpstan to level 6
-
Bump dependencies in composer.json
-
Bump phpstan to level 6
-
WIP - fixup type declarations (test code)
-
ToDo - fixup type declarations (real code)
Towards issue #588
Codecov Report
All modified and coverable lines are covered by tests :white_check_mark:
Comparison is base (
154a84d
) 98.76% compared to head (18494f5
) 98.68%.
:exclamation: Current head 18494f5 differs from pull request most recent head 6f8d36e. Consider uploading reports for the commit 6f8d36e to get more accurate results
Additional details and impacted files
@@ Coverage Diff @@
## master #591 +/- ##
============================================
- Coverage 98.76% 98.68% -0.08%
+ Complexity 1866 1865 -1
============================================
Files 71 71
Lines 5325 5329 +4
============================================
Hits 5259 5259
- Misses 66 70 +4
:umbrella: View full report in Codecov by Sentry.
:loudspeaker: Have feedback on the report? Share it here.
"progress" report: phpstan [ERROR] Found 638 errors
There were 880 errors, I have fixed 242 - that is 27.5% done! This is a painful job.
Types are declared in all test code.
Found 493 errors
Nearly half way. And then need to review what happened and try to tidy it all up, be consistent, and provide the "reasonable most" specific type declarations at each point.
Note to interested people: I have had "other things" happening the last few months. This work here is volunteer work. Hopefully I will get enthusiastic about it again "real soon now" (tm) and have some time to put in.
If anyone else wants to do this stuff, or help with it, feel free to ping me here and we can work out how to move forward.
Rebased and resolved conflicts. Maybe I can get more work done on this "soon".
composer phpstan
...
Found 541 errors
https://github.com/sabre-io/vobject/actions/runs/3985955698/jobs/6833950107
Found 389 errors
I rebased, resolved conflicts, applied the latest cs-fixer code-style changes. Now phpstan
level 6 reports "only":
[ERROR] Found 382 errors
This looks like a big job.
I tried to address some stuff here as well https://github.com/sabre-io/vobject/pull/628/commits