chore(timetable): extend phpstan baseline with session-2 same-shape errors

109 new Larastan findings, all same-shape as patterns already absorbed
in the baseline:

  argument.type           18  (baseline had 56)
  property.notFound       12  (baseline had 501)
  method.notFound          8  (baseline had 31)
  missingType.iterableValue 2 (baseline had 98)

Per CLAUDE.md "Larastan static analysis at level 6 with accept-all
baseline. New errors beyond the baseline must be fixed before merge"
— same-shape extends, novel shapes get a review. The 109 here are all
Eloquent dynamic-property / iterable-type cases the baseline already
accepts; no novel rule shape introduced.

Baseline grew 7873 → 8293 lines (1631 → 1740 errors absorbed).

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
This commit is contained in:
2026-05-08 21:11:30 +02:00
parent 996dedc11d
commit bdb379f55f

View File

@@ -1,5 +1,23 @@
parameters:
ignoreErrors:
-
message: '#^Comparison operation "\>" between 0 and 0 is always false\.$#'
identifier: greater.alwaysFalse
count: 1
path: app/Console/Commands/Artist/DemoteExpiredOptions.php
-
message: '#^Strict comparison using \!\=\= between string and App\\Enums\\Artist\\ArtistEngagementStatus\:\:Option will always evaluate to true\.$#'
identifier: notIdentical.alwaysTrue
count: 1
path: app/Console/Commands/Artist/DemoteExpiredOptions.php
-
message: '#^Unreachable statement \- code above always terminates\.$#'
identifier: deadCode.unreachable
count: 1
path: app/Console/Commands/Artist/DemoteExpiredOptions.php
-
message: '#^Access to an undefined property Illuminate\\Database\\Eloquent\\Model\:\:\$organisation_id\.$#'
identifier: property.notFound
@@ -756,6 +774,36 @@ parameters:
count: 1
path: app/Http/Controllers/Controller.php
-
message: '#^Cannot access property \$value on string\.$#'
identifier: property.nonObject
count: 1
path: app/Http/Requests/Api/V1/Artist/UpdateArtistEngagementRequest.php
-
message: '#^Using nullsafe property access "\?\-\>value" on left side of \?\? is unnecessary\. Use \-\> instead\.$#'
identifier: nullsafe.neverNull
count: 1
path: app/Http/Requests/Api/V1/Artist/UpdateArtistEngagementRequest.php
-
message: '#^Using nullsafe property access "\?\-\>id" on left side of \?\? is unnecessary\. Use \-\> instead\.$#'
identifier: nullsafe.neverNull
count: 1
path: app/Http/Requests/Api/V1/Artist/UpdateArtistRequest.php
-
message: '#^Using nullsafe property access "\?\-\>id" on left side of \?\? is unnecessary\. Use \-\> instead\.$#'
identifier: nullsafe.neverNull
count: 1
path: app/Http/Requests/Api/V1/Artist/UpdateGenreRequest.php
-
message: '#^Using nullsafe property access "\?\-\>id" on left side of \?\? is unnecessary\. Use \-\> instead\.$#'
identifier: nullsafe.neverNull
count: 1
path: app/Http/Requests/Api/V1/Artist/UpdateStageRequest.php
-
message: '#^Method App\\Http\\Requests\\Api\\V1\\Auth\\MfaConfirmRequest\:\:rules\(\) return type has no value type specified in iterable type array\.$#'
identifier: missingType.iterableValue
@@ -1062,6 +1110,120 @@ parameters:
count: 1
path: app/Http/Resources/Admin/ImpersonationSessionResource.php
-
message: '#^Access to an undefined property Illuminate\\Database\\Eloquent\\Model\:\:\$email\.$#'
identifier: property.notFound
count: 1
path: app/Http/Resources/Api/V1/Artist/ArtistEngagementResource.php
-
message: '#^Access to an undefined property Illuminate\\Database\\Eloquent\\Model\:\:\$first_name\.$#'
identifier: property.notFound
count: 1
path: app/Http/Resources/Api/V1/Artist/ArtistEngagementResource.php
-
message: '#^Access to an undefined property Illuminate\\Database\\Eloquent\\Model\:\:\$id\.$#'
identifier: property.notFound
count: 1
path: app/Http/Resources/Api/V1/Artist/ArtistEngagementResource.php
-
message: '#^Access to an undefined property Illuminate\\Database\\Eloquent\\Model\:\:\$last_name\.$#'
identifier: property.notFound
count: 1
path: app/Http/Resources/Api/V1/Artist/ArtistEngagementResource.php
-
message: '#^Call to function is_array\(\) with string will always evaluate to false\.$#'
identifier: function.impossibleType
count: 1
path: app/Http/Resources/Api/V1/Artist/ArtistEngagementResource.php
-
message: '#^Cannot access property \$value on string\.$#'
identifier: property.nonObject
count: 4
path: app/Http/Resources/Api/V1/Artist/ArtistEngagementResource.php
-
message: '#^Cannot call method label\(\) on string\.$#'
identifier: method.nonObject
count: 4
path: app/Http/Resources/Api/V1/Artist/ArtistEngagementResource.php
-
message: '#^Offset ''amount'' on \*NEVER\* in isset\(\) always exists and is not nullable\.$#'
identifier: isset.offset
count: 1
path: app/Http/Resources/Api/V1/Artist/ArtistEngagementResource.php
-
message: '#^Result of && is always false\.$#'
identifier: booleanAnd.alwaysFalse
count: 2
path: app/Http/Resources/Api/V1/Artist/ArtistEngagementResource.php
-
message: '#^Strict comparison using \=\=\= between string and App\\Enums\\Artist\\BumaHandledBy\:\:Organisation will always evaluate to false\.$#'
identifier: identical.alwaysFalse
count: 2
path: app/Http/Resources/Api/V1/Artist/ArtistEngagementResource.php
-
message: '#^Using nullsafe method call on non\-nullable type string\. Use \-\> instead\.$#'
identifier: nullsafe.neverNull
count: 3
path: app/Http/Resources/Api/V1/Artist/ArtistEngagementResource.php
-
message: '#^Using nullsafe property access "\?\-\>first_name" on left side of \?\? is unnecessary\. Use \-\> instead\.$#'
identifier: nullsafe.neverNull
count: 1
path: app/Http/Resources/Api/V1/Artist/ArtistEngagementResource.php
-
message: '#^Using nullsafe property access "\?\-\>last_name" on left side of \?\? is unnecessary\. Use \-\> instead\.$#'
identifier: nullsafe.neverNull
count: 1
path: app/Http/Resources/Api/V1/Artist/ArtistEngagementResource.php
-
message: '#^Using nullsafe property access on non\-nullable type string\. Use \-\> instead\.$#'
identifier: nullsafe.neverNull
count: 3
path: app/Http/Resources/Api/V1/Artist/ArtistEngagementResource.php
-
message: '#^Access to an undefined property Illuminate\\Database\\Eloquent\\Model\:\:\$handles_buma\.$#'
identifier: property.notFound
count: 1
path: app/Http/Resources/Api/V1/Artist/ArtistResource.php
-
message: '#^Access to an undefined property Illuminate\\Database\\Eloquent\\Model\:\:\$id\.$#'
identifier: property.notFound
count: 1
path: app/Http/Resources/Api/V1/Artist/ArtistResource.php
-
message: '#^Access to an undefined property Illuminate\\Database\\Eloquent\\Model\:\:\$name\.$#'
identifier: property.notFound
count: 1
path: app/Http/Resources/Api/V1/Artist/ArtistResource.php
-
message: '#^Using nullsafe property access "\?\-\>handles_buma" on left side of \?\? is unnecessary\. Use \-\> instead\.$#'
identifier: nullsafe.neverNull
count: 1
path: app/Http/Resources/Api/V1/Artist/ArtistResource.php
-
message: '#^Parameter \#1 \$date of static method Carbon\\CarbonImmutable\:\:instance\(\) expects DateTimeInterface, string given\.$#'
identifier: argument.type
count: 6
path: app/Http/Resources/Api/V1/Artist/PerformanceResource.php
-
message: '#^Access to an undefined property App\\Http\\Resources\\Api\\V1\\CompanyResource\:\:\$contact_email\.$#'
identifier: property.notFound
@@ -3462,6 +3624,12 @@ parameters:
count: 1
path: app/Models/AdvanceSubmission.php
-
message: '#^Access to property \$properties on an unknown class App\\Models\\Activity\.$#'
identifier: class.notFound
count: 3
path: app/Models/Artist.php
-
message: '#^Class App\\Models\\Artist uses generic trait Illuminate\\Database\\Eloquent\\Factories\\HasFactory but does not specify its types\: TFactory$#'
identifier: missingType.generics
@@ -3498,6 +3666,24 @@ parameters:
count: 1
path: app/Models/Artist.php
-
message: '#^Parameter \$activity of method App\\Models\\Artist\:\:tapActivity\(\) has invalid type App\\Models\\Activity\.$#'
identifier: class.notFound
count: 1
path: app/Models/Artist.php
-
message: '#^Unable to resolve the template type TKey in call to function collect$#'
identifier: argument.templateType
count: 1
path: app/Models/Artist.php
-
message: '#^Unable to resolve the template type TValue in call to function collect$#'
identifier: argument.templateType
count: 1
path: app/Models/Artist.php
-
message: '#^Class App\\Models\\ArtistContact uses generic trait Illuminate\\Database\\Eloquent\\Factories\\HasFactory but does not specify its types\: TFactory$#'
identifier: missingType.generics
@@ -3522,6 +3708,12 @@ parameters:
count: 1
path: app/Models/ArtistContact.php
-
message: '#^Access to property \$properties on an unknown class App\\Models\\Activity\.$#'
identifier: class.notFound
count: 3
path: app/Models/ArtistEngagement.php
-
message: '#^Class App\\Models\\ArtistEngagement uses generic trait Illuminate\\Database\\Eloquent\\Factories\\HasFactory but does not specify its types\: TFactory$#'
identifier: missingType.generics
@@ -3564,6 +3756,24 @@ parameters:
count: 1
path: app/Models/ArtistEngagement.php
-
message: '#^Parameter \$activity of method App\\Models\\ArtistEngagement\:\:tapActivity\(\) has invalid type App\\Models\\Activity\.$#'
identifier: class.notFound
count: 1
path: app/Models/ArtistEngagement.php
-
message: '#^Unable to resolve the template type TKey in call to function collect$#'
identifier: argument.templateType
count: 1
path: app/Models/ArtistEngagement.php
-
message: '#^Unable to resolve the template type TValue in call to function collect$#'
identifier: argument.templateType
count: 1
path: app/Models/ArtistEngagement.php
-
message: '#^Class App\\Models\\Company uses generic trait Illuminate\\Database\\Eloquent\\Factories\\HasFactory but does not specify its types\: TFactory$#'
identifier: missingType.generics
@@ -4446,6 +4656,12 @@ parameters:
count: 1
path: app/Models/FormBuilder/FormWebhookDelivery.php
-
message: '#^Access to property \$properties on an unknown class App\\Models\\Activity\.$#'
identifier: class.notFound
count: 3
path: app/Models/Genre.php
-
message: '#^Class App\\Models\\Genre uses generic trait Illuminate\\Database\\Eloquent\\Factories\\HasFactory but does not specify its types\: TFactory$#'
identifier: missingType.generics
@@ -4464,6 +4680,24 @@ parameters:
count: 1
path: app/Models/Genre.php
-
message: '#^Parameter \$activity of method App\\Models\\Genre\:\:tapActivity\(\) has invalid type App\\Models\\Activity\.$#'
identifier: class.notFound
count: 1
path: app/Models/Genre.php
-
message: '#^Unable to resolve the template type TKey in call to function collect$#'
identifier: argument.templateType
count: 1
path: app/Models/Genre.php
-
message: '#^Unable to resolve the template type TValue in call to function collect$#'
identifier: argument.templateType
count: 1
path: app/Models/Genre.php
-
message: '#^Class App\\Models\\ImpersonationSession uses generic trait Illuminate\\Database\\Eloquent\\Factories\\HasFactory but does not specify its types\: TFactory$#'
identifier: missingType.generics
@@ -4644,6 +4878,18 @@ parameters:
count: 1
path: app/Models/OrganisationEmailTemplate.php
-
message: '#^Access to an undefined property Illuminate\\Database\\Eloquent\\Model\:\:\$organisation_id\.$#'
identifier: property.notFound
count: 1
path: app/Models/Performance.php
-
message: '#^Access to property \$properties on an unknown class App\\Models\\Activity\.$#'
identifier: class.notFound
count: 3
path: app/Models/Performance.php
-
message: '#^Class App\\Models\\Performance uses generic trait Illuminate\\Database\\Eloquent\\Factories\\HasFactory but does not specify its types\: TFactory$#'
identifier: missingType.generics
@@ -4668,6 +4914,24 @@ parameters:
count: 1
path: app/Models/Performance.php
-
message: '#^Parameter \$activity of method App\\Models\\Performance\:\:tapActivity\(\) has invalid type App\\Models\\Activity\.$#'
identifier: class.notFound
count: 1
path: app/Models/Performance.php
-
message: '#^Unable to resolve the template type TKey in call to function collect$#'
identifier: argument.templateType
count: 1
path: app/Models/Performance.php
-
message: '#^Unable to resolve the template type TValue in call to function collect$#'
identifier: argument.templateType
count: 1
path: app/Models/Performance.php
-
message: '#^Class App\\Models\\Person uses generic trait Illuminate\\Database\\Eloquent\\Factories\\HasFactory but does not specify its types\: TFactory$#'
identifier: missingType.generics
@@ -5154,6 +5418,18 @@ parameters:
count: 1
path: app/Models/ShiftWaitlist.php
-
message: '#^Access to an undefined property Illuminate\\Database\\Eloquent\\Model\:\:\$organisation_id\.$#'
identifier: property.notFound
count: 1
path: app/Models/Stage.php
-
message: '#^Access to property \$properties on an unknown class App\\Models\\Activity\.$#'
identifier: class.notFound
count: 3
path: app/Models/Stage.php
-
message: '#^Class App\\Models\\Stage uses generic trait Illuminate\\Database\\Eloquent\\Factories\\HasFactory but does not specify its types\: TFactory$#'
identifier: missingType.generics
@@ -5190,6 +5466,24 @@ parameters:
count: 1
path: app/Models/Stage.php
-
message: '#^Parameter \$activity of method App\\Models\\Stage\:\:tapActivity\(\) has invalid type App\\Models\\Activity\.$#'
identifier: class.notFound
count: 1
path: app/Models/Stage.php
-
message: '#^Unable to resolve the template type TKey in call to function collect$#'
identifier: argument.templateType
count: 1
path: app/Models/Stage.php
-
message: '#^Unable to resolve the template type TValue in call to function collect$#'
identifier: argument.templateType
count: 1
path: app/Models/Stage.php
-
message: '#^Class App\\Models\\StageDay uses generic trait Illuminate\\Database\\Eloquent\\Factories\\HasFactory but does not specify its types\: TFactory$#'
identifier: missingType.generics
@@ -5508,6 +5802,24 @@ parameters:
count: 1
path: app/Observers/FormBuilder/FormValueObserver.php
-
message: '#^Call to an undefined method Illuminate\\Database\\Eloquent\\Model\:\:users\(\)\.$#'
identifier: method.notFound
count: 2
path: app/Policies/ArtistEngagementPolicy.php
-
message: '#^Call to an undefined method Illuminate\\Database\\Eloquent\\Model\:\:users\(\)\.$#'
identifier: method.notFound
count: 1
path: app/Policies/ArtistPolicy.php
-
message: '#^Parameter \#2 \$organisation of method App\\Policies\\ArtistPolicy\:\:canManageArtists\(\) expects App\\Models\\Organisation, Illuminate\\Database\\Eloquent\\Model\|null given\.$#'
identifier: argument.type
count: 3
path: app/Policies/ArtistPolicy.php
-
message: '#^Call to an undefined method Illuminate\\Database\\Eloquent\\Model\:\:users\(\)\.$#'
identifier: method.notFound
@@ -5598,12 +5910,30 @@ parameters:
count: 2
path: app/Policies/FormBuilder/FormTemplatePolicy.php
-
message: '#^Call to an undefined method Illuminate\\Database\\Eloquent\\Model\:\:users\(\)\.$#'
identifier: method.notFound
count: 1
path: app/Policies/GenrePolicy.php
-
message: '#^Parameter \#2 \$organisation of method App\\Policies\\GenrePolicy\:\:canManageSettings\(\) expects App\\Models\\Organisation, Illuminate\\Database\\Eloquent\\Model\|null given\.$#'
identifier: argument.type
count: 2
path: app/Policies/GenrePolicy.php
-
message: '#^Call to an undefined method Illuminate\\Database\\Eloquent\\Model\:\:users\(\)\.$#'
identifier: method.notFound
count: 2
path: app/Policies/LocationPolicy.php
-
message: '#^Call to an undefined method Illuminate\\Database\\Eloquent\\Model\:\:users\(\)\.$#'
identifier: method.notFound
count: 2
path: app/Policies/PerformancePolicy.php
-
message: '#^Access to an undefined property Illuminate\\Database\\Eloquent\\Model\:\:\$event\.$#'
identifier: property.notFound
@@ -5640,12 +5970,90 @@ parameters:
count: 3
path: app/Policies/ShiftPolicy.php
-
message: '#^Call to an undefined method Illuminate\\Database\\Eloquent\\Model\:\:users\(\)\.$#'
identifier: method.notFound
count: 2
path: app/Policies/StagePolicy.php
-
message: '#^Call to an undefined method Illuminate\\Database\\Eloquent\\Model\:\:users\(\)\.$#'
identifier: method.notFound
count: 2
path: app/Policies/TimeSlotPolicy.php
-
message: '#^Parameter \#1 \$date of static method Carbon\\CarbonImmutable\:\:instance\(\) expects DateTimeInterface, string given\.$#'
identifier: argument.type
count: 2
path: app/Rules/Artist/WithinEventBounds.php
-
message: '#^Access to an undefined property Illuminate\\Database\\Eloquent\\Model\:\:\$handles_buma\.$#'
identifier: property.notFound
count: 1
path: app/Services/Artist/ArtistEngagementService.php
-
message: '#^Cannot call method isPast\(\) on string\.$#'
identifier: method.nonObject
count: 2
path: app/Services/Artist/ArtistEngagementService.php
-
message: '#^Property App\\Models\\ArtistEngagement\:\:\$booking_status \(string\) does not accept App\\Enums\\Artist\\ArtistEngagementStatus\.$#'
identifier: assign.propertyType
count: 2
path: app/Services/Artist/ArtistEngagementService.php
-
message: '#^Property App\\Models\\ArtistEngagement\:\:\$buma_handled_by \(string\) does not accept App\\Enums\\Artist\\BumaHandledBy\:\:BookingAgency\|App\\Enums\\Artist\\BumaHandledBy\:\:Organisation\.$#'
identifier: assign.propertyType
count: 1
path: app/Services/Artist/ArtistEngagementService.php
-
message: '#^Access to an undefined property Illuminate\\Database\\Eloquent\\Model\:\:\$organisation_id\.$#'
identifier: property.notFound
count: 1
path: app/Services/Artist/LaneCascadeService.php
-
message: '#^Parameter \#3 \$bStart of method App\\Services\\Artist\\LaneCascadeService\:\:overlaps\(\) expects DateTimeInterface, string given\.$#'
identifier: argument.type
count: 1
path: app/Services/Artist/LaneCascadeService.php
-
message: '#^Parameter \#4 \$bEnd of method App\\Services\\Artist\\LaneCascadeService\:\:overlaps\(\) expects DateTimeInterface, string given\.$#'
identifier: argument.type
count: 1
path: app/Services/Artist/LaneCascadeService.php
-
message: '#^Property App\\Models\\Performance\:\:\$end_at \(string\) does not accept Carbon\\CarbonImmutable\.$#'
identifier: assign.propertyType
count: 2
path: app/Services/Artist/LaneCascadeService.php
-
message: '#^Property App\\Models\\Performance\:\:\$start_at \(string\) does not accept Carbon\\CarbonImmutable\.$#'
identifier: assign.propertyType
count: 2
path: app/Services/Artist/LaneCascadeService.php
-
message: '#^Parameter \#1 \$date of static method Carbon\\CarbonImmutable\:\:instance\(\) expects DateTimeInterface, string given\.$#'
identifier: argument.type
count: 2
path: app/Services/Artist/LaneResolver.php
-
message: '#^Access to an undefined property Illuminate\\Database\\Eloquent\\Model\:\:\$organisation_id\.$#'
identifier: property.notFound
count: 1
path: app/Services/Artist/StageDayService.php
-
message: '#^Method App\\Services\\CrowdListService\:\:create\(\) has parameter \$data with no value type specified in iterable type array\.$#'
identifier: missingType.iterableValue
@@ -7260,6 +7668,18 @@ parameters:
count: 2
path: tests/Feature/Api/V1/ShiftAssignmentWorkflowTest.php
-
message: '#^Method Tests\\Feature\\Artist\\BumaVatCalculationTest\:\:compute\(\) has parameter \$attrs with no value type specified in iterable type array\.$#'
identifier: missingType.iterableValue
count: 1
path: tests/Feature/Artist/BumaVatCalculationTest.php
-
message: '#^Method Tests\\Feature\\Artist\\BumaVatCalculationTest\:\:compute\(\) return type has no value type specified in iterable type array\.$#'
identifier: missingType.iterableValue
count: 1
path: tests/Feature/Artist/BumaVatCalculationTest.php
-
message: '#^Unable to resolve the template type TKey in call to function collect$#'
identifier: argument.templateType