Review main Abandoned

74821[WIP][FEATURE] Add baseUrl argument to NormalizedUrl vh

Roman Büchler CR 0 V -1 Normal +180 −9 updated 11/10/26, 11:26

Commit message

Initially using this vh with a local file path (e.g.
fileadmin/inage.svg) resulted in an error. While working
on this fix it was found that a file url containing the
host is desired. To build such url's the attribute
`baseUrl` has been introduced.

Review

  • Code review CR 0
  • Verified V -1
    • Helmut Hummel -1

Issues 1

Files 3

Review log 4161

Show 2436 earlier messages
  1. Roman Büchler uploaded patch set 1 06/06/22, 09:17

  2. core-ci voted on patch set 1 V -1 06/06/22, 09:24 Core CI is not happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/27721

  3. Roman Büchler uploaded patch set 2 06/06/22, 09:29

  4. Roman Büchler uploaded patch set 3 06/06/22, 09:32

  5. core-ci voted on patch set 2 V -1 06/06/22, 09:38 Core CI is not happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/27722

  6. core-ci voted on patch set 3 V +1 06/06/22, 09:39 Core CI is happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/27723

  7. Joey Bouten voted on patch set 3 CR +1 06/08/22, 12:23

  8. Oliver Klee updated the commit message in patch set 4 06/09/22, 07:46

  9. Oliver Klee updated the commit message in patch set 5 06/09/22, 07:46

  10. Oliver Klee commented on patch set 5 06/09/22, 07:49

    NormalizedUrlViewHelperTest.php:25

    /** * @covers \TYPO3\CMS\Core\ViewHelpers\NormalizedUrlViewHelper */ This helps reduce false positives when generating code coverage.

    NormalizedUrlViewHelperTest.php:49

    There are two distinct test cases hidden here (as indicated by the "And" in the name). :-) Please let's split this up. (Then we also don't need the data provider anymore.)
  11. core-ci voted on patch set 4 V +1 06/09/22, 07:55 Core CI is happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/27857

  12. core-ci voted on patch set 5 V +1 06/09/22, 07:56 Core CI is happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/27858

  13. Benni Mack updated the commit message in patch set 6 06/09/22, 14:34

  14. core-ci voted on patch set 6 V +1 06/09/22, 14:46 Core CI is happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/27892

  15. Roman Büchler commented on patch set 6 06/11/22, 05:54

    Thank you for the help!

    NormalizedUrlViewHelperTest.php:25 Reply

    Done

    NormalizedUrlViewHelperTest.php:49 Reply

    Done
  16. Roman Büchler uploaded patch set 7 06/11/22, 05:55

  17. core-ci voted on patch set 7 V +1 06/11/22, 06:03 Core CI is happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/27965

  18. Oliver Klee commented on patch set 7 06/11/22, 08:00

    NormalizedUrlViewHelper.php:54

    I don't understand the difference between the host names remote.foo and local.foo here. If they're note relevant. I propose using the recommend dummy host name example.com in all cases.

    NormalizedUrlViewHelper.php:83

    In which cases would the parse_url fail?

    NormalizedUrlViewHelper.php:87

    I'm still trying (and failing) to understand this method. Maybe we could use different local variables for the different kinds of paths to make the implicit differences explicit. What do you think?

    NormalizedUrlViewHelperTest.php:39

    If the exact host name is not relevant, I recommend using one the official dummy host names, e.g. example.com.
  19. Oliver Klee commented on patch set 7 06/11/22, 08:28

    Roman, maybe we can chat about this or work on this together. I couldn't find you on Slack, though. Ping me on Slack if you would like to tackle this together.
  20. Oliver Klee uploaded patch set 8 06/11/22, 10:24

  21. Oliver Klee voted on patch set 8 V +1 CR +1 06/11/22, 10:25

  22. Oliver Klee commented on patch set 8 06/11/22, 10:25

    NormalizedUrlViewHelper.php:54 Reply

    Done

    NormalizedUrlViewHelper.php:83 Reply

    Done

    NormalizedUrlViewHelper.php:87 Reply

    Done
  23. Oliver Klee commented on patch set 8 06/11/22, 10:25

    NormalizedUrlViewHelperTest.php:39 Reply

    Done
  24. core-ci voted on patch set 8 V -1 06/11/22, 10:33 Core CI is not happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/27970

  25. Oliver Klee commented on patch set 8 V -1 CR 0 06/11/22, 10:36

    Oh, this breaks some functional tests. I think we have missed some cases the method also needs to consider.
  26. Oliver Klee commented on patch set 8 06/11/22, 10:37

    (Or we need to adapt the affected functional tests. In any case, we need to investigate the test failures.)
  27. Stefan Bürk commented on patch set 8 06/11/22, 17:11

    NormalizedUrlViewHelper.php:80

    We should avoid using acient GU::getIndpEnv() here and instead use the request (e.g. $renderingContext->getRequest()->getUri()->getHost()). Functional tests has to be adopted to either provider probler global request object / setRequest in the injected rendering context. Or doing executed frontend requests which automatically inject correspondign request objects in the viehelper contexts etc. Also needed to be adjusted in related failing tests.
  28. Roman Büchler uploaded patch set 9 06/18/22, 11:13

  29. core-ci voted on patch set 9 V -1 06/18/22, 11:23 Core CI is not happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/28172

  30. Roman Büchler uploaded patch set 10 06/18/22, 11:36

  31. core-ci voted on patch set 10 V -1 06/18/22, 11:44 Core CI is not happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/28175

  32. Roman Büchler commented on patch set 10 06/18/22, 11:49

    Now functional tests reltaed to - Mail\FluidEmail - Authentication\PasswordReset fail. What do you think should those be adapted?

    NormalizedUrlViewHelper.php:80 Reply

    Done
  33. Roman Büchler uploaded patch set 11 06/19/22, 05:14

  34. core-ci voted on patch set 11 V -1 06/19/22, 05:22 Core CI is not happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/28214

  35. Roman Büchler uploaded patch set 12 06/19/22, 16:33

  36. core-ci voted on patch set 12 V -1 06/19/22, 16:41 Core CI is not happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/28223

  1. Roman Büchler commented on patch set 12 06/19/22, 18:26

    > Patch Set 12: Verified-1 > > Core CI is not happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/28223 The failed test runs successfully through on the local environment using the following command: ``` Build/Scripts/runTests.sh -s acceptance -p 8.1 -d mariadb -i 10.3 typo3/sysext/core/Tests/Acceptance/Application/PageTree/PageTreeFilterCest.php:clearFilterReloadsPageTreeWithoutFilterApplied ``` Do you see what causes the issue?
  2. core-ci commented on patch set 12 06/19/22, 18:31 Core CI is not happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/28223

  3. core-ci voted on patch set 12 V +1 06/19/22, 18:36 Core CI is happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/28223

  4. Stefan Bürk commented on patch set 12 06/19/22, 20:50

    Reply

    PageTreeFilterCest is "known" to be flaky - We had some tried to make it more stable, and Jochen Roth has the task to came up with a better solution for this. Without going to much into detail, it is related to jquery removal and thus not having a proper check for "ajax requests all done" equialent for now as before with jquery - thus this failing on main. But we are on it, so take my apologice for it. However, restartet the failed job pipeline until it went green. Resolving this comment for now, hope this is okay.
  5. Oliver Klee commented on patch set 12 CR -1 06/20/22, 19:12

    -1 until after our call on Thursday :-) (also also due to the added PHPStan warning).
  6. Roman Büchler uploaded patch set 13 06/23/22, 14:46

  7. core-ci voted on patch set 13 V -1 06/23/22, 14:55 Core CI is not happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/28355

  8. Roman Büchler uploaded patch set 14 06/23/22, 15:25

  9. core-ci voted on patch set 14 V +1 06/23/22, 15:33 Core CI is happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/28356

  10. Benni Mack commented on patch set 14 04/14/23, 10:03

    any update here? As v10.4 will soon be out of our support, we should adapt or abandon this change.
  11. Benni Mack updated the commit message in patch set 15 V +1 05/03/23, 09:45

  12. Roman Büchler uploaded patch set 16 05/31/23, 11:39

  13. core-ci voted on patch set 16 V -1 05/31/23, 11:46 Core CI is not happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/42111

  14. Roman Büchler uploaded patch set 17 V -1 05/31/23, 16:05

  15. core-ci voted on patch set 17 V -1 05/31/23, 16:12 Core CI is not happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/42118

  16. Stefan Bürk commented on patch set 17 05/31/23, 16:46

    NormalizedUrlViewHelperTest.php:44 Unresolved

    This should be not needed or ?

    NormalizedUrlViewHelperTest.php:69 Unresolved

    DataProvider must be static

    NormalizedUrlViewHelperTest.php:93 Unresolved

    DataProvider must be static

    NormalizedUrlViewHelperTest.php:115 Unresolved

    DataProvider must be static
  17. Roman Büchler uploaded patch set 18 V -1 05/31/23, 16:56

  18. Roman Büchler uploaded patch set 19 05/31/23, 17:02

  19. core-ci voted on patch set 18 V -1 05/31/23, 17:04 Core CI is not happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/42119

  20. core-ci voted on patch set 19 V +1 05/31/23, 17:09 Core CI is happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/42120

  21. Benni Mack updated the commit message in patch set 20 V +1 10/18/24, 14:07

  22. Helmut Hummel commented on patch set 20 V -1 10/02/25, 09:20

    This will be fixed by https://review.typo3.org/c/Packages/TYPO3.CMS/+/90675 in a global and consistent way. the question is, whether a fix is needed for current typo3 versions
  23. Benni Mack wrote 04/21/26, 14:57

    Removed cc Benni Mack.
  24. Benni Mack marked it work in progress 04/21/26, 14:57

  25. Benni Mack abandoned the change 11/10/26, 11:26