#110859Expose the Extension Scanner as a CLI command upgrade:scan
Description
The gap
The Extension Scanner is reachable only through Admin Tools > Upgrade > Scan
Extension Files. There is no console command, so in a CI pipeline, a pre-upgrade
script or any automated workflow the scanner does not exist.
The scan itself lives inline in UpgradeController::extensionScannerScanFileAction()
(118 lines in v14.3.7), and the matcher registry is a 94-line protected $matchers
property in the same internal@ controller. There is no service to call.
Everyone who needs the scan outside the backend copies both out of the controller.
Besides EXT:install itself, the 23-entry registry is mirrored by hand in
netresearch/nr-extension-scanner-cli dkd-dobberkau/t3corescan .
michielroos/typo3scan reimplements the
scanner altogether.
Scope, as agreed with Benni Mack
- Command
upgrade:scaninEXT:install, registered in itsServiceProvidernext tosetupandinstall:password:set. - The extracted service is public API, not
internal@. - Output: a table and JSON to start with.
Planned change
- Move the matcher registry out of
UpgradeControllerinto one declaration. - Extract the traversal into
ExtensionScannerServicewith typed results (ScanResult,ScanMatch, and anIndicatorenum backed by the existing valuesstrong/weak). - Let
extensionScannerScanFileAction()delegate to the service, so the backend module and the CLI cannot drift apart. The module’s output stays unchanged. - Add
upgrade:scan [extension...] [--format=table|json] [--fail-on=strong|any|none]. By default strong findings and unparsable files make the exit code non-zero.
The extraction is low-risk: between v13.4.35 and v14.3.7 Classes/ExtensionScanner/
kept an identical file list and changed in no public signature.
Patch
Implemented and tested locally against main (unit, install functional, PHPStan,
CGL, and by hand in a running instance). It will go to Gerrit as two changes: the
service extraction and the command, each with a changelog entry.
Related: #110807, #110808
Reviews 3
Related issues 3
History 413
-
Georg Ringer changed Related to #110808 <span data-processor="relativetime" data-value="2026-09-30T11:30:38+00:00" > 09/30/26, 11:30 </span>
-
Georg Ringer changed Related to #110807 <span data-processor="relativetime" data-value="2026-09-30T11:30:46+00:00" > 09/30/26, 11:30 </span>
-
Gerrit Code Review pushed patch set 1 for main to change 96215 status
NewUnder Review <span data-processor="relativetime" data-value="2026-09-30T11:53:28+00:00" > 09/30/26, 11:53 </span> -
Gerrit Code Review pushed patch set 1 for main to change 96216 <span data-processor="relativetime" data-value="2026-09-30T11:53:28+00:00" > 09/30/26, 11:53 </span>
-
Gerrit Code Review pushed patch set 2 for main to change 96215 <span data-processor="relativetime" data-value="2026-09-30T15:41:44+00:00" > 09/30/26, 15:41 </span>
-
Gerrit Code Review pushed patch set 2 for main to change 96216 <span data-processor="relativetime" data-value="2026-09-30T15:41:45+00:00" > 09/30/26, 15:41 </span>
-
Gerrit Code Review pushed patch set 3 for main to change 96216 <span data-processor="relativetime" data-value="2026-10-01T21:39:30+00:00" > 10/01/26, 21:39 </span>
-
Gerrit Code Review pushed patch set 4 for main to change 96216 <span data-processor="relativetime" data-value="2026-10-02T07:43:13+00:00" > 10/02/26, 07:43 </span>
-
Gerrit Code Review pushed patch set 5 for main to change 96216 <span data-processor="relativetime" data-value="2026-10-02T12:31:27+00:00" > 10/02/26, 12:31 </span>
-
Gerrit Code Review pushed patch set 6 for main to change 96216 <span data-processor="relativetime" data-value="2026-10-16T14:21:13+00:00" > 10/16/26, 14:21 </span>
-
Gerrit Code Review pushed patch set 7 for main to change 96216 <span data-processor="relativetime" data-value="2026-10-27T20:14:57+00:00" > 10/27/26, 20:14 </span>
-
Olivier Dobberkau commented and changed status
Under ReviewResolved done0 %100 % <span data-processor="relativetime" data-value="2026-10-27T21:00:18+00:00" > 10/27/26, 21:00 </span> -
Garvin Hicking changed Related to #108414 <span data-processor="relativetime" data-value="2026-11-11T10:47:41+00:00" > 11/11/26, 10:47 </span>
Applied in changeset commit:9cc2be04c51a1c6d356bb4482a60dd145760428d.