psalm.xml 6.0 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154
  1. <?xml version="1.0"?>
  2. <!--
  3. - SPDX-FileCopyrightText: 2020 Nextcloud GmbH and Nextcloud contributors
  4. - SPDX-License-Identifier: AGPL-3.0-or-later
  5. -->
  6. <psalm
  7. errorLevel="4"
  8. resolveFromConfigFile="true"
  9. xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
  10. xmlns="https://getpsalm.org/schema/config"
  11. xsi:schemaLocation="https://getpsalm.org/schema/config"
  12. errorBaseline="build/psalm-baseline.xml"
  13. findUnusedBaselineEntry="false"
  14. findUnusedCode="false"
  15. phpVersion="8.1"
  16. >
  17. <plugins>
  18. <plugin filename="build/psalm/AppFrameworkTainter.php" />
  19. </plugins>
  20. <projectFiles>
  21. <directory name="apps/admin_audit"/>
  22. <directory name="apps/cloud_federation_api"/>
  23. <directory name="apps/comments"/>
  24. <directory name="apps/contactsinteraction"/>
  25. <directory name="apps/dashboard"/>
  26. <directory name="apps/dav"/>
  27. <directory name="apps/encryption"/>
  28. <directory name="apps/federatedfilesharing"/>
  29. <directory name="apps/federation"/>
  30. <directory name="apps/files"/>
  31. <directory name="apps/files_external"/>
  32. <directory name="apps/files_sharing"/>
  33. <directory name="apps/files_trashbin"/>
  34. <directory name="apps/files_versions"/>
  35. <directory name="apps/lookup_server_connector"/>
  36. <directory name="apps/oauth2"/>
  37. <directory name="apps/provisioning_api"/>
  38. <directory name="apps/settings"/>
  39. <directory name="apps/sharebymail"/>
  40. <directory name="apps/systemtags"/>
  41. <directory name="apps/testing"/>
  42. <directory name="apps/theming"/>
  43. <directory name="apps/twofactor_backupcodes"/>
  44. <directory name="apps/updatenotification"/>
  45. <directory name="apps/user_ldap"/>
  46. <directory name="apps/user_status"/>
  47. <directory name="apps/weather_status"/>
  48. <directory name="apps/webhook_listeners"/>
  49. <directory name="apps/workflowengine"/>
  50. <directory name="core"/>
  51. <directory name="lib"/>
  52. <directory name="ocs"/>
  53. <directory name="ocs-provider"/>
  54. <file name="cron.php"/>
  55. <file name="index.php"/>
  56. <file name="public.php"/>
  57. <file name="remote.php"/>
  58. <file name="status.php"/>
  59. <file name="version.php"/>
  60. <ignoreFiles>
  61. <directory name="apps/**/composer"/>
  62. <directory name="apps/**/tests"/>
  63. <directory name="apps/files_external/3rdparty"/>
  64. <directory name="lib/composer"/>
  65. <directory name="lib/l10n"/>
  66. </ignoreFiles>
  67. </projectFiles>
  68. <extraFiles>
  69. <directory name="3rdparty"/>
  70. <directory name="apps/files_external/3rdparty"/>
  71. </extraFiles>
  72. <stubs>
  73. <file name="build/stubs/apcu.php"/>
  74. <file name="build/stubs/gd.php"/>
  75. <file name="build/stubs/imagick.php"/>
  76. <file name="build/stubs/intl.php"/>
  77. <file name="build/stubs/IntlChar.php"/>
  78. <file name="build/stubs/SensitiveParameter.phpstub"/>
  79. <file name="build/stubs/ldap.php"/>
  80. <file name="build/stubs/memcached.php"/>
  81. <file name="build/stubs/redis.php"/>
  82. <file name="build/stubs/redis_cluster.php"/>
  83. <file name="build/stubs/sftp.php"/>
  84. <file name="build/stubs/ssh2.php"/>
  85. <file name="build/stubs/xsl.php"/>
  86. <file name="build/stubs/ftp.php"/>
  87. <file name="build/stubs/pcntl.php"/>
  88. <file name="build/stubs/zip.php"/>
  89. <file name="build/stubs/psr_container.php"/>
  90. <file name="3rdparty/sabre/uri/lib/functions.php" />
  91. <file name="build/stubs/app_api.php" />
  92. </stubs>
  93. <issueHandlers>
  94. <LessSpecificReturnStatement errorLevel="error"/>
  95. <LessSpecificReturnType errorLevel="error"/>
  96. <LessSpecificImplementedReturnType errorLevel="error"/>
  97. <MoreSpecificReturnType errorLevel="error"/>
  98. <UndefinedClass>
  99. <errorLevel type="suppress">
  100. <referencedClass name="OCA\Circles\CirclesManager"/>
  101. <referencedClass name="OCA\Circles\Exceptions\CircleNotFoundException"/>
  102. <referencedClass name="OCA\Circles\Model\Circle"/>
  103. <referencedClass name="OCA\Circles\Model\Member"/>
  104. <referencedClass name="OCA\GroupFolders\Mount\GroupFolderStorage"/>
  105. <referencedClass name="OCA\TwoFactorNextcloudNotification\Controller\APIController"/>
  106. <referencedClass name="OCA\GlobalSiteSelector\Service\SlaveService"/>
  107. </errorLevel>
  108. </UndefinedClass>
  109. <UndefinedFunction>
  110. <errorLevel type="suppress">
  111. <!-- template functions: https://github.com/nextcloud/server/blob/6e8e34fef920a073118c22111f0f31eb3b3a91dc/lib/private/legacy/template/functions.php -->
  112. <referencedFunction name="p"/>
  113. <referencedFunction name="emit_css_tag"/>
  114. <referencedFunction name="emit_css_loading_tags"/>
  115. <referencedFunction name="emit_script_tag"/>
  116. <referencedFunction name="emit_script_loading_tags"/>
  117. <referencedFunction name="print_unescaped"/>
  118. <referencedFunction name="script"/>
  119. <referencedFunction name="vendor_script"/>
  120. <referencedFunction name="style"/>
  121. <referencedFunction name="vendor_style"/>
  122. <referencedFunction name="translation"/>
  123. <referencedFunction name="component"/>
  124. <referencedFunction name="link_to"/>
  125. <referencedFunction name="link_to_docs"/>
  126. <referencedFunction name="image_path"/>
  127. <referencedFunction name="mimetype_icon"/>
  128. <referencedFunction name="preview_icon"/>
  129. <referencedFunction name="publicPreview_icon"/>
  130. <referencedFunction name="human_file_size"/>
  131. <referencedFunction name="strip_time"/>
  132. <referencedFunction name="relative_modified_date"/>
  133. <referencedFunction name="html_select_options"/>
  134. </errorLevel>
  135. </UndefinedFunction>
  136. <UndefinedGlobalVariable>
  137. <errorLevel type="suppress">
  138. <referencedVariable name="$_"/>
  139. <referencedVariable name="$l"/>
  140. <referencedVariable name="$theme"/>
  141. <!-- false positive: https://github.com/nextcloud/server/blob/cb057829f72c70e819f456edfadbb29d72dba832/lib/private/Console/Application.php#L92 -->
  142. <file name="core/register_command.php" />
  143. </errorLevel>
  144. </UndefinedGlobalVariable>
  145. <UndefinedDocblockClass>
  146. <errorLevel type="suppress">
  147. <!-- Helper classes for sharing API integration from other apps -->
  148. <referencedClass name="OCA\Deck\Sharing\ShareAPIHelper" />
  149. <referencedClass name="OCA\Talk\Share\Helper\DeletedShareAPIController" />
  150. <referencedClass name="OCA\GlobalSiteSelector\Service\SlaveService"/>
  151. </errorLevel>
  152. </UndefinedDocblockClass>
  153. </issueHandlers>
  154. </psalm>