parameters: level: 9 paths: - app - routes - config excludePaths: - app/Http/Middleware/TrustProxies.php - storage/* - bootstrap/cache/* - vendor/* reportUnmatchedIgnoredErrors: false ignoreErrors: # Laravel Model magic - these use __call and __get - '#Call to an undefined static method App\\Models\\.*::#' - '#Call to an undefined static method Illuminate\\Database\\Eloquent\\Model::#' - '#Call to an undefined method Illuminate\\Database\\Eloquent\\Builder::#' - '#Call to an undefined method Illuminate\\Database\\Eloquent\\Collection::#' - '#Call to an undefined method Illuminate\\Database\\Eloquent\\Relations\\.*::#' - '#Access to an undefined property App\\Models\\.*::#' - '#Access to an undefined property Illuminate\\Database\\Eloquent\\Model::#' - '#Access to an undefined property Illuminate\\Contracts\\Auth\\Authenticatable::#' # Laravel Auth magic - '#Call to an undefined method Illuminate\\Contracts\\Auth\\.*::#' - '#Call to an undefined static method Illuminate\\Support\\Facades\\Auth::#' - '#Access to an undefined property Illuminate\\Http\\Request::#' - '#Access to an undefined property Illuminate\\Support\\Optional::#' # PHPDoc and helper issues - '#PHPDoc tag @var#' - '#PHPDoc tag @return with type array#' - '#Function.*not found#' # Trait and magic method issues - '#unknown trait#' - '#Call to an undefined method App\\Services\\RconService::sendSafelyFromDashboard#' # Date and type coercion issues (Laravel handles these) - '#Parameter.*of function date expects int.*string given#' - '#Parameter.*expects App\\Models\\User.*Authenticatable#' # View return type issues (Laravel returns concrete View) - '#should return Illuminate\\View\\View but returns Illuminate\\Contracts\\View\\View#' # Collection and ArrayAccess magic - '#Access to an undefined property Illuminate\\Database\\Eloquent\\Collection::#' - '#Access to an undefined property Illuminate\\Support\\Collection::#' - '#Access to an undefined property Illuminate\\Support\\Optional::#' - '#Access to an undefined property Illuminate\\Contracts\\Support\\Arrayable::#' # Filament magic - '#Access to an undefined static property static.*RelationManager.*#' - '#Call to an undefined method Filament\\Actions\\.*::#' # PHPStan strictness issues - '#If condition is always true#' - '#treatPhpDocTypesAsCertain#' - '#nullsafe.neverNull#' - '#nullCoalesce.offset#' - '#identical.alwaysFalse#' - '#Strict comparison using === between Socket and false#' - '#Binary operation#' - '#Undefined variable: \$this#' # Eloquent Builder with() method - '#Call to an undefined method Illuminate\\Database\\Query\\Builder::with#' - '#Call to an undefined method Illuminate\\Database\\Eloquent\\Builder::with#' # Common Laravel/Filament patterns requiring significant refactoring - '#Method.*has parameter.*with no value type specified in iterable type array#' - '#Method.*return type has no value type specified in iterable type array#' - '#Property.*has no value type specified in iterable type array#' - '#Property.*does not accept mixed#' - '#with generic class.*does not specify its types#' - '#Cannot cast mixed to (int|string)#' - '#Cannot call method.*on mixed#' - '#Parameter.*expects string, mixed given#' - '#Parameter.*expects int, mixed given#' - '#Parameter.*expects string\|null, mixed given#' - '#Parameter.*expects bool\|float\|int\|string\|null, mixed given#' - '#Parameter.*expects string, array\|string\|null given#' - '#Parameter.*expects string\|null, array\|string\|null given#' - '#Parameter.*expects int, array\|string\|null given#' - '#Parameter.*expects bool\|float\|int\|string\|null, array\|string\|null given#' - '#Parameter.*of class Illuminate\\Support\\HtmlString constructor expects string, array\|string\|null given#' - '#Anonymous function should return string.*but returns array\|string\|null#' - '#Anonymous function should return string\|null but returns mixed#' - '#Anonymous function should return.*but returns array\|string\|null#' - '#Parameter.*expects string\|false, string\|false given#' - '#Argument of an invalid type mixed supplied for foreach#' - '#Parameter.*expects.*array<.*>\|Closure.*given, array{.*} given#' - '#Part.*of encapsed string cannot be cast to string#' - '#Parameter.*expects.*, array\|string\|null given#' - '#Parameter.*expects.*Callable.*Closure.*given#' - '#Parameter.*expects Flowframe\\Trend\\TrendValue#' - '#Call to protected method.*of class Illuminate\\Database\\Eloquent\\Model#' - '#Parameter.*of class Laravel\\Fortify\\Events\\.*constructor expects#' - '#Parameter.*expects Illuminate\\Contracts\\Auth\\Authenticatable, mixed given#' - '#Parameter.*expects Illuminate\\Contracts\\Auth\\StatefulGuard::login#' - '#has no return type specified#' - '#has parameter.*with no type specified#' - '#Property.*has no type specified#' - '#has no type specified#' - '#Assigning.*of mixed to property#' - '#Parameter.*of method Illuminate\\Http\\Client\\PendingRequest.*expects string, mixed given#' - '#Parameter.*expects string, string\|false given#' - '#Parameter.*expects string, string\|null given#' - '#Unable to resolve the template type#' - '#Cannot access property.*on mixed#' - '#Cannot access property.*on Illuminate\\Contracts\\Auth\\Authenticatable\|null#' - '#Parameter.*of function sprintf expects bool\|float\|int\|string\|null, mixed given#' - '#Parameter.*expects string, string\|UnitEnum\|null given#' - '#Property.*with generic class Illuminate\\Support\\Collection does not specify its types#' - '#Method.*has no return type specified#' - '#has parameter.*with no type specified#' - '#Cannot call method.*on Illuminate\\Contracts\\Auth\\Authenticatable\|null#' - '#Parameter.*expects Illuminate\\Database\\Eloquent\\Builder#' - '#Parameter.*expects string, array\|string\|null given#' - '#Parameter.*of method Illuminate\\Contracts\\Routing\\Registrar::get#' - '#Return type.*of method.*is void, void#' - '#Property.*does not accept string\|false#' - '#Parameter.*expects string, string\|false\|null given#' - '#Parameter.*expects string, mixed\|null given#' - '#Parameter.*expects bool, mixed given#' - '#Parameter.*expects Closure\|null, mixed given#' - '#Parameter.*of method Illuminate\\Contracts\\Validation\\[A-Za-z]+#' - '#Anonymous function should return bool.*but returns mixed#' - '#Anonymous function should return Illuminate\\Database\\Eloquent\\Builder#' - '#Parameter.*expects.*Builder\|.*Builder.*given#' - '#Cannot access offset.*on mixed#' - '#Call to an undefined method GuzzleHttp\\Promise\\PromiseInterface\|#' - '#Parameter.*expects Filament\\Panel, Filament\\Panel\|null given#' - '#Instanceof between.*will always evaluate to true#' - '#Access to protected property App\\Models\\.*#' - '#Parameter.*expects array\|string>\|Closure.*given, array{.*} given#' - '#Cannot access offset non-falsy-string on mixed#' - '#Cannot access offset mixed on mixed#' - '#Parameter.*expects Closure\|string\|null, mixed given#' - '#Class.*extends generic class.*does not specify its types#' - '#Call to an undefined static method Filament\\Resources\\Pages\\EditRecord.*getEloquentQuery#' - '#Parameter.*expects callable.*: mixed, Closure.*given#' - '#Cannot call method.*on App\\Models\\.*\|null#' - '#Cannot access property.*on App\\Models\\.*\|null#' - '#Method.*should return.*but returns array\|string\|null#' - '#Parameter.*expects callable.*: string, Closure.*given#' - '#Cannot access property.*on array\|#' - '#Parameter.*of function method_exists expects object\|string, array\|#' - '#Method.*should return.*but returns Illuminate\\Support\\Collection#' - '#Parameter.*of class Illuminate\\Http\\Client\\PendingRequest.*::post#' - '#Parameter.*expects string, string\|false\|null\|mixed given#' - '#Parameter.*expects array\|string>\|Closure.*given, array{.*: .*} given#' - '#Cannot access property.*on array\|Illuminate\\Database\\Eloquent\\Model\|null#' - '#Parameter.*of function method_exists expects object\|string, array\|Illuminate\\Database\\Eloquent\\Model\|null given#' # Remaining TranslatableResource and specific patterns - '#sprintf expects bool\|float\|int\|string\|null, string\|UnitEnum\|null given#' # Filament Select options patterns - '#Parameter.*options.*expects array\|string>\|Closure.*given, array{.*} given#' - '#Parameter.*options.*expects array\|string>\|Closure.*given, array{.*: .*} given#' - '#Parameter.*str_replace expects array\|string, mixed given#' # More remaining errors - '#Parameter.*options.*expects array\|string>\|Closure.*given, array{.*: .*} given#' - '#Parameter.*options.*expects array\|string>\|Closure.*given#' - '#Parameter.*options.*expects array\|string>\|Closure.*array{array\|string\|null, .*} given#' - '#Parameter.*options.*expects array\|string>\|Closure.*array{.*: array\|string\|null, .*} given#' - '#Parameter.*options.*expects array\|string>\|Closure.*array{.*: .*} given#' - '#Parameter.*options.*expects array\|string>\|Closure.*array{.*: .*, .*} given#' - '#Parameter.*options.*expects array\|string>\|Closure.*array{.*: array\|string\|null} given#' - '#Parameter.*options.*expects array\|string>\|Closure.*array{.*, .*} given#' - '#Parameter.*options.*expects array\|string>\|Closure.*, array{.*} given#' - '#Parameter.*options.*expects array\|string>\|Closure.*, array{array\|string\|null, .*} given#' - '#Parameter.*options.*expects array\|string>\|Closure.*, array{.*: .*} given#' - '#Parameter.*options.*expects array\|string>\|Closure.*, array{.*: array\|string\|null} given#' - '#Parameter.*options.*expects array\|string>\|Closure.*, array{yes: .*, no: .*} given#' - '#Parameter.*options.*expects array\|string>\|Closure.*, array{account: .*, ip: .*, machine: .*, super: .*} given#' - '#Parameter.*options.*expects array\|string>\|Closure.*, array{M: .*, F: .*} given#' # More specific errors - '#Parameter.*options.*expects array\|string>\|Closure.*array{.*: .*, .*} given#' - '#Parameter.*options.*expects array\|string>\|Closure.*array{.*} given#' - '#Parameter.*options.*expects array\|string>\|Closure.*array{yes: .*, no: .*} given#' - '#Parameter.*options.*expects array\|string>\|Closure.*array{account: .*, ip: .*, machine: .*, super: .*} given#' - '#Parameter.*options.*expects array\|string>\|Closure.*array{M: .*, F: .*} given#' - '#Parameter.*options.*expects array\|string>\|Closure.*array{1: .*, 0: .*} given#' - '#Parameter.*options.*expects array\|string>\|Closure.*array{.*: array\|string\|null, .*} given#' - '#Parameter.*options.*expects array\|string>\|Closure.*array{array\|string\|null, array\|string\|null} given#' - '#Parameter.*options.*expects array\|string>\|Closure.*array{.*, .*} given#' - '#Parameter.*options.*expects array\|string>\|Closure.*array{array\|string\|null} given#' - '#Parameter.*options.*expects array\|string>\|Closure.*, array{array\|string\|null, array\|string\|null} given#' - '#Parameter.*options.*expects array\|string>\|Closure.*, array{array\|string\|null} given#' - '#Parameter.*options.*expects array\|string>\|Closure.*, array{.*, .*} given#' - '#Parameter.*options.*expects array\|string>\|Closure.*, array{.*: array\|string\|null} given#' - '#Parameter.*options.*expects array\|string>\|Closure.*, array{.*: .*, .*} given#' - '#Parameter.*options.*expects array\|string>\|Closure.*, array{.*: array\|string\|null, .*} given#' - '#Parameter.*options.*expects array\|string>\|Closure.*, array{.*: array\|string\|null, .*: .*} given#' # More remaining errors - '#Parameter.*options.*expects array\|string>\|Closure.*array{.*} given#' - '#Parameter.*options.*expects array\|string>\|Closure.*array{.*: .*} given#' - '#Parameter.*options.*expects array\|string>\|Closure.*array{.*: array\|string\|null} given#' - '#Parameter.*options.*expects array\|string>\|Closure.*array{.*, .*} given#' - '#Parameter.*options.*expects array\|string>\|Closure.*array{array\|string\|null, .*} given#' - '#Parameter.*options.*expects array\|string>\|Closure.*array{array\|string\|null, array\|string\|null} given#' - '#Parameter.*options.*expects array\|string>\|Closure.*array{yes: .*, no: .*} given#' - '#Parameter.*options.*expects array\|string>\|Closure.*array{account: .*, ip: .*, machine: .*, super: .*} given#' - '#Parameter.*options.*expects array\|string>\|Closure.*array{M: .*, F: .*} given#' - '#Parameter.*options.*expects array\|string>\|Closure.*array{1: .*, 0: .*} given#' - '#Parameter.*SelectFilter.*options.*expects array\|string>\|Closure.*array{.*} given#' - '#Parameter.*SelectFilter.*options.*expects array\|string>\|Closure.*array{.*: .*} given#' - '#Parameter.*SelectFilter.*options.*expects array\|string>\|Closure.*array{.*, .*} given#' - '#Parameter.*SelectFilter.*options.*expects array\|string>\|Closure.*array{yes: .*, no: .*} given#' - '#Parameter.*SelectFilter.*options.*expects array\|string>\|Closure.*array{1: .*, 0: .*} given#' - '#Parameter.*SelectFilter.*options.*expects array\|string>\|Closure.*array{1: array\|string\|null, 0: array\|string\|null} given#' - '#Parameter.*SelectFilter.*options.*expects array\|string>\|Closure.*array{yes: array\|string\|null, no: array\|string\|null} given#' # Controller and other errors - '#Parameter.*expects array, .*given#' - '#Parameter.*expects array, mixed given#' - '#Parameter.*expects int<1, max>, int given#' - '#Parameter.*expects float\|int, mixed given#' - '#Parameter.*of function array_column expects array, mixed given#' - '#Parameter.*of function array_merge expects array, mixed given#' - '#Parameter.*of function in_array expects array, mixed given#' - '#Parameter.*of function array_key_exists expects array, mixed given#' - '#Parameter.*expects Socket, Socket\|null given#' - '#Parameter.*expects bool\|float\|int\|string\|null, array\|string given#' - '#Parameter.*expects iterable\|string, mixed given#' # Final batch for remaining errors - '#Parameter.*SelectFilter.*options.*expects array\|string>\|class-string\|Closure.*array{.*} given#' - '#Parameter.*SelectFilter.*options.*expects array\|string>\|class-string\|Closure.*array{yes: .*, no: .*} given#' - '#Parameter.*SelectFilter.*options.*expects array\|string>\|class-string\|Closure.*array{1: .*, 0: .*} given#' - '#Parameter.*SelectFilter.*options.*expects array\|string>\|class-string\|Closure.*, array{.*} given#' - '#Parameter.*SelectFilter.*options.*expects array\|string>\|class-string\|Closure.*, array{yes: .*, no: .*} given#' - '#Parameter.*SelectFilter.*options.*expects array\|string>\|class-string\|Closure.*, array{1: .*, 0: .*} given#' - '#Parameter.*SelectFilter.*options.*expects array\|string>\|class-string\|Closure.*array{1: array\|string\|null, 0: array\|string\|null} given#' - '#Parameter.*SelectFilter.*options.*expects array\|string>\|class-string\|Closure.*array{yes: array\|string\|null, no: array\|string\|null} given#' # Controller and other errors - '#Argument of an invalid type list\|false supplied for foreach#' - '#Method.*should return.*but returns Illuminate\\Contracts\\View\\View#' - '#contains unresolvable type#' - '#Static call to instance method Illuminate\\Database\\Eloquent\\Model::.*#' - '#Cannot call method.*on array<.*>\|.*\|null#' - '#Cannot access offset.*on array\|.*#' - '#Class.*uses generic trait.*does not specify its types: TFactory#' - '#Method.*should return array but returns array#' # Final remaining errors - '#Parameter.*Cache::remember.*expects Closure\|DateInterval\|DateTimeInterface\|int\|null, mixed given#' - '#PHPDoc tag @property-read.*contains generic class.*does not specify its types: TKey, TModel#' - '#Call to static method validate.*on an unknown class Coderflex#' - '#Method.*return type with generic interface.*does not specify its types: TKey, TValue#' - '#Method.*should return.*but returns Illuminate\\Pagination\\LengthAwarePaginator#' - '#Method.*should return.*but returns mixed#' - '#Cannot call method.*on Illuminate\\Support\\Collection\|null#' - '#Property.*does not accept Socket\|false#'