-
Notifications
You must be signed in to change notification settings - Fork 5
Expand file tree
/
Copy pathpsalm.xml
More file actions
263 lines (262 loc) · 17.6 KB
/
Copy pathpsalm.xml
File metadata and controls
263 lines (262 loc) · 17.6 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
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
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
<?xml version="1.0"?>
<psalm
errorLevel="4"
resolveFromConfigFile="true"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xmlns="https://getpsalm.org/schema/config"
findUnusedBaselineEntry="true"
findUnusedCode="true"
findUnusedVariablesAndParams="true"
>
<projectFiles>
<directory name="lib" />
<ignoreFiles>
<directory name="vendor" />
</ignoreFiles>
</projectFiles>
<stubs>
<file name="vendor/nextcloud/ocp/OCP/Capabilities/ICapability.php" preloadClasses="true" />
</stubs>
<issueHandlers>
<UndefinedDocblockClass errorLevel="suppress"/>
<UndefinedClass>
<errorLevel type="suppress">
<!-- Nextcloud's legacy bootstrap class. There is no OCP
interface for registering another app's autoloader, so the
ADR-040 AppHost prelude in AppInfo\Application has to call
OC_App::registerAutoloading() directly. It is server-private
and therefore absent from nextcloud/ocp, which is why psalm
cannot see it. Same suppression, same reason, as doriath. -->
<referencedClass name="OC_App"/>
<!-- Nextcloud OCP Classes -->
<referencedClass name="OCP\AppFramework\App"/>
<referencedClass name="OCP\AppFramework\Bootstrap\IBootstrap"/>
<referencedClass name="OCP\AppFramework\Controller"/>
<referencedClass name="OCP\AppFramework\IAppContainer"/>
<referencedClass name="OCP\App\IAppManager"/>
<referencedClass name="OCP\BackgroundJob\IJobList"/>
<referencedClass name="OCP\BackgroundJob\QueuedJob"/>
<referencedClass name="OCP\BackgroundJob\TimedJob"/>
<referencedClass name="OCP\EventDispatcher\Event"/>
<referencedClass name="OCP\EventDispatcher\IEventListener"/>
<referencedClass name="OCP\IAppConfig"/>
<referencedClass name="OCP\ICacheFactory"/>
<referencedClass name="OCP\IConfig"/>
<referencedClass name="OCP\IDBConnection"/>
<referencedClass name="OCP\IGroupManager"/>
<referencedClass name="OCP\IUserManager"/>
<referencedClass name="OCP\IUserSession"/>
<referencedClass name="OCP\IMemcache"/>
<referencedClass name="OCP\IRequest"/>
<referencedClass name="OCP\EventDispatcher\IEventDispatcher"/>
<referencedClass name="OCP\DB\QueryBuilder\IQueryBuilder"/>
<referencedClass name="OCP\AppFramework\Db\QBMapper"/>
<referencedClass name="OCP\AppFramework\Db\Entity"/>
<referencedClass name="OCP\Files\IRootFolder"/>
<referencedClass name="OCP\Files\Node"/>
<referencedClass name="OCP\Files\File"/>
<referencedClass name="OCP\Files\Folder"/>
<referencedClass name="OCP\Files\NotFoundException"/>
<referencedClass name="OCP\AppFramework\Http\JSONResponse"/>
<referencedClass name="OCP\AppFramework\Http\TemplateResponse"/>
<referencedClass name="OCP\AppFramework\Http\DataResponse"/>
<referencedClass name="OCP\IL10N"/>
<referencedClass name="OCP\IURLGenerator"/>
<referencedClass name="OCP\Http\Client\IClient"/>
<referencedClass name="OCP\Http\Client\IClientService"/>
<referencedClass name="OCP\Notification\IManager"/>
<referencedClass name="OCP\Share\IManager"/>
<!-- OpenRegister cross-app classes (loaded dynamically) -->
<referencedClass name="OCA\OpenRegister\Db\ObjectEntity"/>
<referencedClass name="OCA\OpenRegister\Db\RegisterMapper"/>
<referencedClass name="OCA\OpenRegister\Db\SchemaMapper"/>
<referencedClass name="OCA\OpenRegister\Event\DeepLinkRegistrationEvent"/>
<referencedClass name="OCA\OpenRegister\Event\ObjectCreatingEvent"/>
<referencedClass name="OCA\OpenRegister\Event\ObjectCreatedEvent"/>
<referencedClass name="OCA\OpenRegister\Event\ObjectUpdatingEvent"/>
<referencedClass name="OCA\OpenRegister\Event\ObjectUpdatedEvent"/>
<referencedClass name="OCA\OpenRegister\Event\ObjectDeletedEvent"/>
<referencedClass name="OCA\OpenRegister\Service\ObjectService"/>
<referencedClass name="OCA\OpenRegister\Service\Credential\CredentialBrokerService"/>
<referencedClass name="OCA\OpenRegister\Service\Credential\CredentialAccessDeniedException"/>
<referencedClass name="OCA\OpenRegister\Service\Credential\CredentialUpstreamException"/>
<referencedClass name="OCA\OpenRegister\Service\ConfigurationService"/>
<referencedClass name="OCA\OpenRegister\Service\RegisterService"/>
<referencedClass name="OCA\OpenRegister\Service\FileService"/>
<referencedClass name="OCA\OpenRegister\Service\CalendarEventService"/>
<referencedClass name="OCA\OpenRegister\Service\Handoff\HandoffService"/>
<referencedClass name="OCA\OpenRegister\Exception\HandoffException"/>
<referencedClass name="OCA\OpenRegister\Exception\NotAuthorizedException"/>
<referencedClass name="OCA\OpenRegister\Mcp\IMcpToolProvider"/>
<!-- ADR-078 actor-forwarded deferral contract. ViewDeletedEventListener
hands its cascade to DeferredViewCascadeJob through
ListenerDeferralService instead of running it inside the user's
delete request; both types live in OpenRegister and are resolved
at runtime, exactly like ObjectService above. -->
<referencedClass name="OCA\OpenRegister\Service\Deferral\ListenerDeferralService"/>
<referencedClass name="OCA\OpenRegister\Service\Deferral\DeferredListenerContext"/>
<referencedClass name="OCA\OpenRegister\Service\OrganisationService"/>
<referencedClass name="OCA\OpenRegister\BackgroundJob\ActorForwardedJob"/>
<!-- OpenRegister flow-engine types. Present only at runtime, and only on an
OpenRegister that ships the flow engine — which is exactly what the
class_exists() guard in Application::registerFlowNodes() is for. The
same three files are already excluded from PHPStan for this reason. -->
<referencedClass name="OCA\OpenRegister\Service\Flow\RegisterFlowNodesEvent"/>
<!-- FlowSuspension is the engine's "pause this run" signal, raised by the
nodes that a source can rate-limit. FlowRateLimit builds it and is the
one flow helper that references an OpenRegister flow type WITHOUT also
implementing IFlowNode, so it is analysed rather than skipped and needs
the suppression named explicitly. -->
<referencedClass name="OCA\OpenRegister\Service\Flow\FlowSuspension"/>
<!-- Same reasoning for mapping: the engine is OpenRegister's and this app
only CONTRIBUTES the three functions needing its own services. The
addServiceListener registration is lazy, so the class is never touched
on an instance without OpenRegister. -->
<referencedClass name="OCA\OpenRegister\Service\RegisterMappingFunctionsEvent"/>
<referencedClass name="OCA\OpenRegister\Service\Flow\IFlowNode"/>
<!-- Used by the MaterializeCatalogItems repair step to run a write as the
system operator; resolved from OpenRegister at runtime. -->
<referencedClass name="OCA\OpenRegister\Service\SystemOperationContext"/>
<!-- Additional OCP infrastructure types used across the fleet -->
<referencedClass name="OCP\AppFramework\Bootstrap\IBootContext"/>
<referencedClass name="OCP\AppFramework\Bootstrap\IRegistrationContext"/>
<referencedClass name="OCP\AppFramework\Db\DoesNotExistException"/>
<referencedClass name="OCP\DB\Exception"/>
<referencedClass name="OCP\IGroup"/>
<referencedClass name="OCP\IUser"/>
<referencedClass name="OCP\Migration\IRepairStep"/>
<!-- Nextcloud server internals -->
<referencedClass name="OC"/>
<referencedClass name="OC\AppFramework\Middleware\Security\Exceptions\SecurityException"/>
<referencedClass name="OC\Files\Node\File"/>
<!-- flow-workflowengine-integration: NC's concrete IRequest implementation,
synthesized by EndpointService::buildSyntheticRequest() (design.md Decision 5) -->
<referencedClass name="OC\AppFramework\Http\Request"/>
<!-- flow-workflowengine-integration: NC core's only bundled WorkflowEngine IEntity,
referenced only as a compile-time ::class string by the three operation classes -->
<referencedClass name="OCA\WorkflowEngine\Entity\File"/>
<!-- GuzzleHttp (loaded via composer at runtime) -->
<referencedClass name="GuzzleHttp\Client"/>
<referencedClass name="GuzzleHttp\Exception\GuzzleException"/>
<!-- OR AppHost controllers (loaded via DI at runtime) -->
<referencedClass name="OCA\OpenRegister\AppHost\Controller\GenericHealthController"/>
<referencedClass name="OCA\OpenRegister\AppHost\Controller\GenericMetricsController"/>
<referencedClass name="OCA\OpenRegister\AppHost\Controller\GenericPreferencesController"/>
<referencedClass name="OCA\OpenRegister\AppHost\IMetricsProvider"/>
<referencedClass name="OCA\OpenRegister\AppHost\Observability\ManifestLoader"/>
<referencedClass name="OCA\OpenRegister\AppHost\Observability\HealthCheckExecutor"/>
<referencedClass name="OCA\OpenRegister\AppHost\Observability\MetricsEngine"/>
<!-- OR AppHost boilerplate (adopt-apphost: Settings/Section + InitializeActions) -->
<referencedClass name="OCA\OpenRegister\AppHost\Repair\GenericInitializeActions"/>
<referencedClass name="OCA\OpenRegister\AppHost\Service\GenericActionAuthService"/>
<referencedClass name="OCA\OpenRegister\AppHost\Settings\GenericAdminSettings"/>
<referencedClass name="OCA\OpenRegister\AppHost\Settings\GenericSettingsSection"/>
<!-- Service classes from OpenRegister used via OR integration layer -->
<referencedClass name="OCA\OpenRegister\Service\OrganisationService"/>
<referencedClass name="OCA\OpenRegister\Service\RegisterResolverService"/>
<referencedClass name="OCA\OpenRegister\Service\Integration\AbstractIntegrationProvider"/>
<referencedClass name="OCA\OpenRegister\Service\Integration\IntegrationRegistry"/>
<referencedClass name="OCA\OpenRegister\Service\Integration\IntegrationProvider"/>
<referencedClass name="OCA\OpenRegister\Db\Mapping"/>
<!-- Symfony (loaded at runtime via Nextcloud or composer require) -->
<referencedClass name="Symfony\Component\ExpressionLanguage\ExpressionLanguage"/>
<referencedClass name="Symfony\Component\HttpKernel\Exception\TooManyRequestsHttpException"/>
<!-- Additional Nextcloud server internals -->
<referencedClass name="OC\AppFramework\Http"/>
<referencedClass name="OC\User\NoUserException"/>
<!-- OpenRegister additional runtime classes -->
<referencedClass name="OCA\OpenRegister\Service\ObjectServiceMapperAdapter"/>
<referencedClass name="OCA\OpenRegister\Exception\ValidationException"/>
<!-- PHP extension classes (loaded at runtime) -->
<referencedClass name="SoapFault"/>
<!-- Legacy Integriq Rule type (deleted entity; survives only as FQCN in one method) -->
<referencedClass name="OCA\Integriq\Service\Rule"/>
<!-- nextcloud-event-hub: NC-core-app / optional-app event classes
referenced only via `::class` (compile-time string) and
instanceof (safe when the class is absent). OCA\DAV\* is an NC
core app; OCA\Tables\* / OCA\Forms\* are optional App Store apps —
none is present in the standalone vendor tree. See design.md
Decision 1 and each listener's class docblock.
The three OCP\Calendar\Events\* entries that used to sit here are
GONE (#1174). Their reason was "`@since 32.0.0`, newer than the
pinned nextcloud/ocp: dev-stable29 dev dependency" — true when
written, false once this repo pinned nextcloud/ocp ^32.0. Those
classes now ship in vendor/nextcloud/ocp and psalm analyses them
for real, so suppressing UndefinedClass on them would only hide a
future rename. -->
<referencedClass name="OCA\DAV\Events\CachedCalendarObjectCreatedEvent"/>
<referencedClass name="OCA\DAV\Events\CachedCalendarObjectUpdatedEvent"/>
<referencedClass name="OCA\DAV\Events\CachedCalendarObjectDeletedEvent"/>
<referencedClass name="OCA\Tables\Event\RowAddedEvent"/>
<referencedClass name="OCA\Tables\Event\RowUpdatedEvent"/>
<referencedClass name="OCA\Tables\Event\RowDeletedEvent"/>
<referencedClass name="OCA\Forms\Events\FormSubmittedEvent"/>
<!-- OCP\SystemTag\MapperEvent is real OCP present in the vendored stubs;
listed for documentation completeness of the file-tag producer. -->
<referencedClass name="OCP\SystemTag\MapperEvent"/>
</errorLevel>
</UndefinedClass>
<!-- UndefinedMethod: suppress known false positives from interface types (OCP\IRequest::server,
OCP\Files\Node::putContent, etc.) where the concrete class has the method at runtime -->
<UndefinedMethod errorLevel="suppress"/>
<UndefinedMagicMethod errorLevel="suppress"/>
<UnusedClass errorLevel="suppress"/>
<PossiblyUnusedMethod errorLevel="suppress"/>
<UnusedMethod errorLevel="suppress"/>
<UnusedProperty errorLevel="suppress"/>
<PossiblyUnusedParam errorLevel="suppress"/>
<UnusedDocblockParam errorLevel="suppress"/>
<UnusedVariable errorLevel="suppress"/>
<UnusedParam errorLevel="suppress"/>
<UnusedClosureParam errorLevel="suppress"/>
<UnusedFunctionCall errorLevel="suppress"/>
<UnusedReturnValue errorLevel="suppress"/>
<PossiblyUnusedReturnValue errorLevel="suppress"/>
<RedundantCondition errorLevel="suppress"/>
<RedundantFunctionCall errorLevel="suppress"/>
<RedundantCast errorLevel="suppress"/>
<InvalidDocblock errorLevel="suppress"/>
<MoreSpecificImplementedParamType errorLevel="suppress"/>
<MissingDependency errorLevel="suppress"/>
<UnevaluatedCode errorLevel="suppress"/>
<NoValue errorLevel="suppress"/>
<TypeDoesNotContainNull errorLevel="suppress"/>
<TypeDoesNotContainType errorLevel="suppress"/>
<InvalidArrayOffset errorLevel="suppress"/>
<InvalidCast errorLevel="suppress"/>
<InvalidArgument errorLevel="suppress"/>
<InvalidReturnType errorLevel="suppress"/>
<InvalidReturnStatement errorLevel="suppress"/>
<MismatchingDocblockReturnType errorLevel="suppress"/>
<MismatchingDocblockParamType errorLevel="suppress"/>
<EmptyArrayAccess errorLevel="suppress"/>
<ImplementedReturnTypeMismatch errorLevel="suppress"/>
<InvalidMethodCall errorLevel="suppress"/>
<UndefinedInterfaceMethod errorLevel="suppress"/>
<MissingTemplateParam errorLevel="suppress"/>
<!-- Suppress Psalm patterns that are runtime-correct but statically unknown -->
<NoInterfaceProperties errorLevel="suppress"/>
<InvalidThrow errorLevel="suppress"/>
<InvalidScalarArgument errorLevel="suppress"/>
<InvalidPropertyAssignmentValue errorLevel="suppress"/>
<UndefinedThisPropertyFetch errorLevel="suppress"/>
<UndefinedConstant errorLevel="suppress"/>
<UndefinedFunction errorLevel="suppress"/>
<TooFewArguments errorLevel="suppress"/>
<NullableReturnStatement errorLevel="suppress"/>
<InvalidOperand errorLevel="suppress"/>
<UndefinedVariable errorLevel="suppress"/>
<!-- FlowNodeListener implements IEventListener<RegisterFlowNodesEvent>. Psalm cannot
see that the OpenRegister event extends OCP\EventDispatcher\Event (the class is
runtime-only, see the referencedClass entries above), so it reports the template
param as invalid. Scoped to the one listener rather than suppressed globally. -->
<InvalidTemplateParam>
<errorLevel type="suppress">
<file name="lib/Flow/FlowNodeListener.php"/>
</errorLevel>
</InvalidTemplateParam>
</issueHandlers>
<extraFiles>
<directory name="vendor/nextcloud/ocp" />
</extraFiles>
</psalm>