Skip to content

Conversation

@dbellettini
Copy link
Member

@dbellettini dbellettini commented Aug 17, 2025

This is the highest level before everything stops working (still figuring out why)

@dbellettini dbellettini self-assigned this Aug 17, 2025
@dbellettini dbellettini force-pushed the phpstan-max branch 10 times, most recently from 5707477 to 3847ab0 Compare August 17, 2025 21:44
@dbellettini dbellettini changed the title Increase PHPStan level Increase PHPStan level to 6 Aug 17, 2025
@dbellettini dbellettini marked this pull request as ready for review August 17, 2025 21:45
@dbellettini dbellettini requested a review from Copilot August 17, 2025 21:45
Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull Request Overview

This PR increases the PHPStan static analysis level from 5 to 6, which requires more strict type annotations and removes type inference for certain scenarios. The changes primarily focus on adding proper type hints, parameter and return type annotations, and detailed PHPDoc comments throughout the codebase to satisfy the stricter analysis requirements.

Key changes include:

  • Added comprehensive type annotations to method parameters and return types
  • Enhanced PHPDoc comments with detailed array shapes and generic types
  • Fixed type-related issues identified by the higher PHPStan level
  • Added proper type assertions and null checks for better type safety

Reviewed Changes

Copilot reviewed 71 out of 71 changed files in this pull request and generated 3 comments.

Show a summary per file
File Description
phpstan.neon Updated PHPStan level from 5 to 6 and added configuration for stricter analysis
Multiple test files Added type hints to closures, method parameters, and enhanced PHPDoc annotations
Multiple source files Added comprehensive type annotations, return types, and detailed array shape documentation
src/Recruiter/functions.php Enhanced array_group_by function with proper generics and type safety
src/Recruiter/Infrastructure/Command/OptionTools.php New utility trait for type-safe option handling

Tip: Customize your code reviews with copilot-instructions.md. Create the file or learn how to get started.

dbellettini and others added 2 commits August 18, 2025 01:15
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
@dbellettini dbellettini merged commit 74ea927 into main Nov 18, 2025
4 checks passed
@dbellettini dbellettini deleted the phpstan-max branch November 18, 2025 08:17
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.

1 participant