forked from dotclear/dotclear
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathphpstan.neon
239 lines (192 loc) · 7.12 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
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
#
# To run analyse:
# bin/phpstan analyse --memory-limit=-1
#
# or (replacing conf level by 1, … up to 9):
# bin/phpstan analyse -l 1 --memory-limit=-1
includes:
# - phpstan.local.neon
parameters:
level: 5
editorUrl: 'file://%%file%%'
bootstrapFiles:
- phpstan.bootstrap
fileExtensions:
- php
- in
scanFiles:
- index.php
paths:
- admin
- inc
- src
- plugins
- themes/berlin
- themes/blowup
- themes/blueSilence
- themes/customCSS
- themes/ductile
excludePaths:
- inc/config.php
dynamicConstantNames:
- DC_ADBLOCKER_CHECK
- DC_ADMIN_SSL
- DC_ADMIN_URL
- DC_AKISMET_SUPER
- DC_ALLOW_MULTI_MODULES
- DC_ALLOW_REPOSITORIES
- DC_ANTISPAM_CONF_SUPER
- DC_BACKUP_PATH
- DC_CRYPT_ALGO
- DC_CSP_LOGFILE
- DC_DBDRIVER
- DC_DBHOST
- DC_DBNAME
- DC_DBPASSWORD
- DC_DBPREFIX
- DC_DBUSER
- DC_DEBUG
- DC_DEFAULT_JQUERY
- DC_DEFAULT_THEME
- DC_DEFAULT_TPLSET
- DC_DEV
- DC_DIGESTS
- DC_DISTRIB_PLUGINS
- DC_DISTRIB_THEMES
- DC_DNSBL_SUPER
- DC_ERRORFILE
- DC_FAIRTRACKBACKS_FORCE
- DC_FORCE_SCHEME_443
- DC_L10N_ROOT
- DC_L10N_UPDATE_URL
- DC_MASTER_KEY
- DC_MAX_UPLOAD_SIZE
- DC_NEXT_REQUIRED_PHP
- DC_NOT_UPDATE
- DC_PLUGINS_ROOT
- DC_QUERY_TIMEOUT
- DC_RC_PATH
- DC_REST_SERVICES
- DC_REVERSE_PROXY
- DC_ROOT
- DC_SESSION_NAME
- DC_SESSION_TTL
- DC_STORE_NOT_UPDATE
- DC_TPL_CACHE
- DC_UPDATE_URL
- DC_UPDATE_VERSION
- DC_VAR
- DC_VENDOR_NAME
- DC_VERSION
- DC_XMLRPC_URL
- HTTP_PROXY_HOST
- HTTP_PROXY_PORT
reportUnmatchedIgnoredErrors: false
ignoreErrors:
# $this variable may not be defined (plugins/themes)
- message: '#Variable \$this might not be defined#'
path: */*/_define.php
# dcAdmin object and auto properties
- message: '#Access to an undefined property dcAdmin::#'
path: %currentWorkingDirectory%
# dcNamespace object and auto properties
- message: '#Access to an undefined property dcNamespace::#'
path: %currentWorkingDirectory%
# context object and auto properties
- message: '#Access to an undefined property context::#'
path: %currentWorkingDirectory%
# dcWidgets object and auto properties
- message: '#Access to an undefined property dcWidgets::#'
path: %currentWorkingDirectory%
# dcWidgets object methods
- message: '#Call to an undefined method dcWidgets::#'
path: %currentWorkingDirectory%
# dcWidget object and auto properties
- message: '#Access to an undefined property dcWidget::#'
path: %currentWorkingDirectory%
# dcWidget object methods
- message: '#Call to an undefined method dcWidget::#'
path: %currentWorkingDirectory%
# dcSettings object and auto properties
- message : '#Access to an undefined property dcSettings::#'
path: %currentWorkingDirectory%
# dcPrefs object and auto properties
- message : '#Access to an undefined property dcPrefs::#'
path: %currentWorkingDirectory%
# Intensive use of magic __set/__get/__call/__invoke causes theses wrong warnings
- message: '#Call to an undefined method form[a-zA-Z0-9\\_]+::#'
path: %currentWorkingDirectory%
# Intensive use of magic __set/__get/__call/__invoke causes theses wrong warnings
- message: '#Access to an undefined property form[a-zA-Z0-9\\_]+::#'
path: %currentWorkingDirectory%
# form<*>filters
- message: '#Access to an undefined property admin[a-zA-Z0-9\\_]+Filter::\$[a-zA-Z0-9\\_]+.#'
path: %currentWorkingDirectory%
# dcAdminfilters
- message: '#Access to an undefined property dcAdminFilter::\$[a-zA-Z0-9\\_]+.#'
path: %currentWorkingDirectory%
# adminMediaPage
- message: '#Access to an undefined property adminMediaPage::\$[a-zA-Z0-9\\_]+.#'
path: %currentWorkingDirectory%
# arrayObject/type
- message: '#ArrayObject\<\*NEVER\*, \*NEVER\*\> does not accept#'
path: %currentWorkingDirectory%
# dcAdmin::$widgets user-defined properties
- message: '#Access to an undefined property dcCore::\$widgets.#'
path: %currentWorkingDirectory%
# dcAdmin::$default_widgets user-defined properties
- message: '#Access to an undefined property dcCore::\$default_widgets.#'
path: %currentWorkingDirectory%
# formXXX
- message: '#Access to an undefined property \$this\(form[a-zA-Z0-9\\_]+\)::#'
path: %currentWorkingDirectory%
# 2.25+
# WidgetsStack object and auto properties
- message: '#Access to an undefined property Dotclear\\Plugin\\widgets\\WidgetsStack::#'
path: %currentWorkingDirectory%
# WidgetsElement object and auto properties
- message: '#Access to an undefined property Dotclear\\Plugin\\widgets\\WidgetsElement::#'
path: %currentWorkingDirectory%
# dcModuleDefine auto properties
- message: '#Access to an undefined property dcModuleDefine::#'
path: %currentWorkingDirectory%
# 2.26+
# Intensive use of magic __set/__get/__call/__invoke causes theses wrong warnings
- message: '#Call to an undefined method Dotclear\\Helper\\Html\\Form\\[a-zA-Z0-9\\_]+::#'
path: %currentWorkingDirectory%
# Intensive use of magic __set/__get/__call/__invoke causes theses wrong warnings
- message: '#Access to an undefined property Dotclear\\Helper\\Html\\Form\\[a-zA-Z0-9\\_]+::#'
path: %currentWorkingDirectory%
# XmlTag object and magic properties
- message: '#Access to an undefined property Dotclear\\Helper\\Html\\XmlTag::#'
path: %currentWorkingDirectory%
# XmlTag object and magic methods
- message : '#Call to an undefined method Dotclear\\Helper\\Html\\XmlTag::#'
path: %currentWorkingDirectory%
# Intensive use of magic __set/__get/__call/__invoke causes theses wrong warnings
- message : '#Access to an undefined property Dotclear\\Helper\\File\\File::#'
path: %currentWorkingDirectory%
# Record object and auto properties
- message: '#Access to an undefined property Dotclear\\Database\\Record::#'
path: %currentWorkingDirectory%
# Cursor object and auto properties
- message : '#Access to an undefined property Dotclear\\Database\\Cursor::#'
path: %currentWorkingDirectory%
# MetaRecord object and auto properties
- message: '#Access to an undefined property Dotclear\\Database\\MetaRecord::#'
path: %currentWorkingDirectory%
# MetaRecord object methods
- message: '#Call to an undefined method Dotclear\\Database\\MetaRecord::#'
path: %currentWorkingDirectory%
# Structure object and auto properties
- message: '#Access to an undefined property Dotclear\\Database\\Structure::#'
path: %currentWorkingDirectory%
# getDefines() ambiguous return value
- message: '#Call to an undefined method object::addMissing\(\).#'
path: */*/inc/core/class.dc.modules.php
- message: '#Call to an undefined method object::getId\(\).#'
path: */*/inc/core/class.dc.modules.php
# Notes:
#
# Use /* @phpstan-ignore-next-line */ or // @phpstan-ignore-line
# to ignore some specific lines in code