-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathphpstan.neon
62 lines (47 loc) · 2.76 KB
/
phpstan.neon
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
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
includes:
- vendor/phpstan/phpstan-doctrine/extension.neon
- vendor/symplify/phpstan-extensions/config/config.neon
- vendor/symplify/coding-standard/config/symplify-rules.neon
parameters:
symplify:
max_cognitive_complexity: 8
paths:
- "src"
- "packages"
level: max
reportUnmatchedIgnoredErrors: false
checkGenericClassInNonGenericObjectType: false
checkMissingIterableValueType: false
excludes_analyse:
- "*/Entity*"
- '*/var/cache/*'
- '*/var/log/*'
- 'statie/tests'
# temporary
- 'packages/Youtube/src/FacebookVideosProvider/PehapkariFacebookPageVideosProvider.php'
- 'packages/Marketing/src/Social/FacebookPublisher.php'
ignoreErrors:
# known value
- '#Method Pehapkari\\Statie\\Posts\\Year2018\\Cart\\Infrastructure\\DoctrineCartRepository::find\(\) should Pehapkari\\Statie\\Posts\\Year2018\\Cart\\Domain\\Cart\|null but returns object\|null#'
- '#Method Pehapkari\\Github\\EventSubscriber\\CatchTemplateEventSubscriber\:\:resolveControllerMethod\(\) should return string but returns object\|string#'
- '#Parameter \#1 \$object of function get_class expects object, object\|string given#'
# mixed
- '#with no typehint specified#'
- '#Parameter \#1 \$argument of class ReflectionClass constructor expects class\-string<T of object\>\|T of object, string given#'
- '#Call to method setRelativeUploadDestination\(\) on an unknown class Pehapkari\\BetterEasyAdmin\\Entity\\UploadableImageTrait#'
- '#PHPDoc tag @var for property Pehapkari\\Blog\\Posts\\Year2018\\Cart\\Domain\\Cart\:\:\$items contains unresolvable type#'
- '#Property Pehapkari\\Youtube\\Repository\\VideoRepository\:\:\$livestreamVideos \(array<Pehapkari\\Youtube\\ValueObject\\LivestreamVideo\>\) does not accept array<object\>#'
- '#Method Pehapkari\\Blog\\Repository\\OrganizerRepository\:\:fetchAll\(\) should return array<Pehapkari\\ValueObject\\Organizer\> but returns array<object\>#'
# nette magic
-
message: "#^Use explicit property fetch names over dynamic$#"
count: 2
path: src/Twig/Extension/LatteFiltersExtension.php
# improve original rule later
- '#Class "(Price|ZipCode)" with static method must have "static" in its name#'
- '#Cannot cast array<string\>\|string\|null to string#'
-
message: "#^Use explicit property fetch names over dynamic$#"
count: 2
path: packages/blog/src/Posts/Year2017/NetteConfigObjects/Config/AbstractConfig.php
- '#Method Pehapkari\\Blog\\Posts\\Year2017\\SymfonyValidatorConditionalConstraints\\Client\:\:getType\(\) should return int but returns int\|null#'