Review main Merged

71892[BUGFIX] Avoid deprecated methods in DebuggerUtility

Stefan Bürk CR +2 V +2 Normal +76 −4 updated 10/19/21, 21:40

Commit message

Extbase DebuggerUtility uses reflection to determine
information that should be rendered as debug output
in 'renderContent()'.

PHP 8.0 deprecated some methods of ReflectionParameter
which will be removed in PHP 9.0.

This patch avoids the deprecation message using the
alternative way to get these informations.

Additionally tests are added to cover the behaviour.

Review

  • Code review CR +2 Done
    • Christian Kuhn +2
    • Wouter Wolters +1
  • Verified V +2 Done
    • Christian Kuhn +2
    • Wouter Wolters +1
    • core-ci +1 CI

Issues 1

Files 2

Review log 1520

  1. Stefan Bürk uploaded patch set 1 10/19/21, 16:40

  2. Stefan Bürk updated the commit message in patch set 2 10/19/21, 16:46

  3. core-ci voted on patch set 1 V +1 10/19/21, 16:53 Core CI is happy: https://gitlab.typo3.org/typo3/CI/cms/-/pipelines/18332

  4. core-ci voted on patch set 2 V +1 10/19/21, 17:00 Core CI is happy: https://gitlab.typo3.org/typo3/CI/cms/-/pipelines/18333

  5. Christian Kuhn commented on patch set 2 10/19/21, 17:16

    DebuggerUtility.php:626

    does this need a getTypes() fallback, too?
  6. Christian Kuhn uploaded patch set 3 10/19/21, 17:16

  7. Christian Kuhn commented on patch set 3 10/19/21, 17:17

    this should have some dedicated php >= 8.0 tests.
  8. Christian Kuhn voted on patch set 3 CR -1 10/19/21, 17:17

  9. Christian Kuhn commented on patch set 3 10/19/21, 17:27

    UnitTests.xml:48

    ah, i shouldn't have pushed this.
  10. Christian Kuhn uploaded patch set 4 10/19/21, 17:27

  11. core-ci voted on patch set 3 V -1 10/19/21, 17:29 Core CI is not happy: https://gitlab.typo3.org/typo3/CI/cms/-/pipelines/18335

  12. core-ci voted on patch set 4 V +1 10/19/21, 17:40 Core CI is happy: https://gitlab.typo3.org/typo3/CI/cms/-/pipelines/18336

  13. Christian Kuhn commented on patch set 4 CR -1 10/19/21, 20:08

    we'll try to come up with some tests.
  14. Stefan Bürk uploaded patch set 5 10/19/21, 20:32

  15. Stefan Bürk commented on patch set 5 10/19/21, 20:38

    Reply

    I added some tests in general. Tests for "union type" (8.0) or "union intersect types" (8.1) are not possible, as these would be compile errors instantly. As the goal was to avoid the depcrecation method, and the reflection do not take other types than "array" or a "class" into account, I would ommit this for now. DebuggerUtillity should be revisted / overworked if php 8.1 is min req, and as such these types can be supported.

    DebuggerUtility.php:626 Reply

    Removed that methods, and as such - no.
  16. core-ci voted on patch set 5 V +1 10/19/21, 20:44 Core CI is happy: https://gitlab.typo3.org/typo3/CI/cms/-/pipelines/18344

  17. Christian Kuhn voted on patch set 5 V +1 CR +1 10/19/21, 20:48

  18. Wouter Wolters voted on patch set 5 V +1 CR +1 10/19/21, 21:05

  19. Christian Kuhn voted on patch set 5 V +2 CR +2 10/19/21, 21:39

  20. Christian Kuhn merged patch set 6 10/19/21, 21:40