Repository navigation
Expand file tree
/
Copy pathphpstan.neon
More file actions
42 lines (36 loc) · 2.25 KB
/
Copy pathphpstan.neon
File metadata and controls
42 lines (36 loc) · 2.25 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
parameters:
level: 5
# composer.lock is not committed, so CI runs newer dependency/PHPStan
# versions whose error message wording can drift from the local setup;
# a pattern that stops matching must not itself become a failure.
reportUnmatchedIgnoredErrors: false
paths:
- src/
excludePaths:
- src/Controller/AppController.php
bootstrapFiles:
- vendor/autoload.php
ignoreErrors:
# CakePHP plugin - App classes don't exist in plugin context
- '#Instantiated class App\\Mailer\\UserMailer not found#'
- '#Call to method send\(\) on an unknown class App\\Mailer\\UserMailer#'
# CakePHP i18n function loaded at runtime
- '#Function __ not found#'
# CakePHP constant loaded at runtime
- '#Constant ROOT not found#'
# Optional dependency - BaconQrCode
- '#class BaconQrCode\\#'
# PHPDoc type certainty - false positives
- '#Strict comparison using [!=]== between .* will always evaluate to#'
# CakePHP Entity magic property access - EntityInterface does not declare dynamic properties
# but CakePHP Entity supports __get/__set for all columns including plugin-internal fields.
- '#Access to an undefined property Cake\\Datasource\\EntityInterface::\$email_verification_token#'
- '#Access to an undefined property Cake\\Datasource\\EntityInterface::\$_verification_login_required#'
- '#Access to an undefined property Cake\\Datasource\\EntityInterface::\$_verification_login_code_sent#'
- '#Access to an undefined property Cake\\Datasource\\EntityInterface::\$_verification_login_triggered_id#'
# Dynamic object property access via getOriginalData() which returns mixed narrowed to object.
# These properties are plugin-internal state flags set on CakePHP Entity objects at runtime.
# Newer PHPStan reports the type with generics (ArrayAccess<string, mixed>), older without.
- '#Access to an undefined property ArrayAccess(<[^>]*>)?::\$_verification_login_required#'
- '#Access to an undefined property ArrayAccess(<[^>]*>)?::\$_verification_login_code_sent#'
- '#Access to an undefined property ArrayAccess(<[^>]*>)?::\$_verification_login_triggered_id#'