Review main Merged Breaking

79884[!!!][TASK] Introduce type declarations in DriverInterface

Alexander Schnitzler CR +2 V +2 Hard +373 −320 updated 07/19/23, 10:28

Commit message

Return and param type declarations have been introduced for all
methods stubs of \TYPO3\CMS\Core\Resource\Driver\DriverInterface.

Also, method sanitizeFileName() of abstract class
\TYPO3\CMS\Core\Resource\Driver\AbstractDriver has been removed.

Review

  • Code review CR +2 Done
    • Stefan Bürk +2
    • Christian Kuhn +1
  • Verified V +2 Done
    • Stefan Bürk +2
    • Christian Kuhn +1
    • core-ci +1 CI

Issues 1

Files 8

Review log 2028

Show 23 earlier messages
  1. Alexander Schnitzler uploaded patch set 1 07/09/23, 08:54

  2. core-ci voted on patch set 1 V -1 07/09/23, 09:03 Core CI is not happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/43955

  3. Alexander Schnitzler uploaded patch set 2 V -1 07/09/23, 16:48

  1. core-ci voted on patch set 2 V +1 07/09/23, 16:56 Core CI is happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/43958

  2. Alexander Schnitzler uploaded patch set 3 V +1 07/11/23, 07:54

  3. Alexander Schnitzler wrote 07/11/23, 07:57

    Topic set to FAL
  4. core-ci voted on patch set 3 V +1 07/11/23, 08:02 Core CI is happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/44012

  5. Alexander Schnitzler marked it ready for review 07/11/23, 08:05

  6. Oliver Klee commented on patch set 3 V +1 07/11/23, 09:54

    DriverInterface.php:121

    `?string` (also in the implementing classes)

    DriverInterface.php:137

    While we're at it: `@return array<string, string>` (also in the implementing classes)

    DriverInterface.php:181

    Is this a `non-empty-string`?

    DriverInterface.php:202

    Is this a `non-empty-string`?

    DriverInterface.php:285

    Nitpick: `int<0, max>` (with the space added)

    DriverInterface.php:323

    Nitpick: `{r: bool, w: bool}`

    DriverInterface.php:334

    `: void`

    DriverInterface.php:365

    Do we know more about the array?

    DriverInterface.php:367

    `: array`

    DriverInterface.php:383

    Nitpick (2x): Please let's have a space after the comma for improved readability. Ditto for the other occurrences in this file.

    DriverInterface.php:401

    `: array`

    DriverInterface.php:436

    `: array`
  7. Alexander Schnitzler rebased onto patch set 4 V +1 07/18/23, 13:57

  8. core-ci voted on patch set 4 V +1 07/18/23, 14:10 Core CI is happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/44259

  9. Alexander Schnitzler uploaded patch set 5 V +1 07/18/23, 14:15

  10. Alexander Schnitzler commented on patch set 5 07/18/23, 14:17

    DriverInterface.php:121 Reply

    Done

    DriverInterface.php:137 Reply

    Done

    DriverInterface.php:181 Reply

    Done

    DriverInterface.php:202 Reply

    Done

    DriverInterface.php:285 Reply

    Done

    DriverInterface.php:323 Reply

    Done

    DriverInterface.php:334 Reply

    Done

    DriverInterface.php:365 Reply

    Done

    DriverInterface.php:367 Reply

    Done

    DriverInterface.php:383 Reply

    Done

    DriverInterface.php:401 Reply

    Done

    DriverInterface.php:436 Reply

    Done
  11. core-ci voted on patch set 5 V +1 07/18/23, 14:23 Core CI is happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/44261

  12. Oliver Klee voted on patch set 5 V +1 CR +1 07/18/23, 14:37

  13. Christian Kuhn rebased onto patch set 6 CR +1 V +1 07/19/23, 08:53

  14. core-ci voted on patch set 6 V +1 07/19/23, 09:00 Core CI is happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/44297

  15. Christian Kuhn uploaded patch set 7 V +1 07/19/23, 09:22

  16. Christian Kuhn voted on patch set 7 V +1 CR +1 07/19/23, 09:22

  17. core-ci voted on patch set 7 V +1 07/19/23, 09:29 Core CI is happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/44300

  18. Stefan Bürk commented on patch set 7 07/19/23, 09:50

    DriverInterface.php:365

    This should be `@return array{` without the space: See: https://phpstan.org/r/72c63067-e727-4a81-9cf3-720829c69613 (ok) vs.: https://phpstan.org/r/11e9b704-e1c7-45c1-b456-3fdef8ee5c35 (error) Could not find andy information since which version PHPStan supports multiline array shapes. Have we the min version already required for this ? Maybe the space check comes with a higher level. @Oliver Klee, does you have some more information on this ?
  19. Alexander Schnitzler commented on patch set 7 07/19/23, 10:07

    DriverInterface.php:365 Reply

    https://phpstan.org/writing-php-code/phpdoc-types#array-shapes doesn't state a version number, therefore I take it this feature had been added before the stable 1.0.0. phpstan doesn't find the issue because we are on level 5 and this error is raised as of level 6.
  20. Alexander Schnitzler uploaded patch set 8 CR +1 V +1 07/19/23, 10:13

  21. core-ci voted on patch set 8 V +1 07/19/23, 10:20 Core CI is happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/44302

  22. Christian Kuhn voted on patch set 8 V +1 CR +1 07/19/23, 10:23

  23. Stefan Bürk voted on patch set 8 V +2 CR +2 07/19/23, 10:28

  24. Stefan Bürk commented on patch set 8 07/19/23, 10:28

    DriverInterface.php:365 Reply

    Done
  25. Stefan Bürk merged patch set 9 07/19/23, 10:28