Review main Merged

68202[BUGFIX] Auto redirect resolve target page

Guido Schmechel CR +2 V +2 Normal +43 −32 updated 09/24/21, 09:08

Commit message

When renaming pages, the pages in the automatic
redirect are now saved with the TYPO3 protocol.

Review

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

Issues 1

Files 2

Review log 3548

Show 1523 earlier messages
  1. Guido Schmechel uploaded patch set 1 03/07/21, 09:13

  2. TYPO3com voted on patch set 1 V -1 03/07/21, 09:20 Completed build in 06m 08s on Sun, 7 Mar, 09:20 AM Test Summary: 18 of 32986 failed Find logs and detail information at https://bamboo.typo3.com/browse/CORE-GTC-9899

  3. core-ci voted on patch set 1 V -1 03/07/21, 09:27 Core CI is not happy: https://core.b13.com/typo3-core/typo3.cms/-/pipelines/1241

  4. Guido Schmechel commented on patch set 1 03/20/21, 10:18

    TODO: Clarify how we handle this fixed t3 identifier. Despite from the tests and the final decision the fix is already working.
  5. Guido Schmechel uploaded patch set 2 04/09/21, 20:55

  6. TYPO3com voted on patch set 2 V -1 04/09/21, 21:02 Completed build in 07m 06s on Fri, 9 Apr, 09:02 PM Test Summary: 6 of 33503 failed Find logs and detail information at https://bamboo.typo3.com/browse/CORE-GTC-10590

  7. core-ci voted on patch set 2 V -1 04/09/21, 21:08 Core CI is not happy: https://core.b13.com/typo3-core/typo3.cms/-/pipelines/2157

  8. Guido Schmechel uploaded patch set 3 04/09/21, 21:48

  9. Guido Schmechel rebased onto patch set 4 04/09/21, 21:49

  10. TYPO3com voted on patch set 4 V +1 04/09/21, 21:57 Completed build in 07m 36s on Fri, 9 Apr, 09:57 PM Test Summary: 33267 passed Find logs and detail information at https://bamboo.typo3.com/browse/CORE-GTC-10595

  11. TYPO3com voted on patch set 3 V +1 04/09/21, 21:58 Completed build in 08m 59s on Fri, 9 Apr, 09:58 PM Test Summary: 33267 passed Find logs and detail information at https://bamboo.typo3.com/browse/CORE-GTC-10594

  12. core-ci voted on patch set 3 V +1 04/09/21, 21:59 Core CI is happy: https://core.b13.com/typo3-core/typo3.cms/-/pipelines/2161

  13. core-ci voted on patch set 4 V +1 04/09/21, 22:01 Core CI is happy: https://core.b13.com/typo3-core/typo3.cms/-/pipelines/2162

  14. Guido Schmechel commented on patch set 4 CR -1 04/09/21, 22:24

    Follow up: - In general: Maybe to breaking for 10.x? - Integrity check must be modified (LinkService?) -1 for now
  15. Guido Schmechel wrote 04/11/21, 16:35

    Removed Code-Review-1 by Guido Schmechel <guido.schmechel@brandung.de>
  16. Guido Schmechel commented on patch set 4 04/11/21, 16:54

    Reply

    Integrity Check successfully checked
  17. Jochen Roth voted on patch set 4 V +1 CR +1 04/19/21, 13:28

  18. Jochen Roth wrote 04/19/21, 13:32

    Removed Verified+1 by Jochen <rothjochen@gmail.com>
  19. Jochen Roth wrote 04/19/21, 13:32

    Removed Code-Review+1 by Jochen <rothjochen@gmail.com>
  20. Jochen Roth commented on patch set 4 04/19/21, 13:38

    On translations i'm getting the following: > The page did not exist or was inaccessible. Reason: The requested page does not exist On default language it is working.
  21. Guido Schmechel commented on patch set 4 04/19/21, 13:44

    Reply

    Hi Jochen, thanks for your feedback So the redirect itself was created correctly in the backend, but the redirection does not work? Or did you get the hint somewhere beforehand?
  22. Jochen Roth commented on patch set 4 04/20/21, 10:15

    Reply

    Yes, redirects in 'target' are created correctly. Here are the results: /en/translateme-more-more-more t3://page?uid=48 --> WORKS /en/translated-redirect-test t3://page?uid=48 --> DOES NOT WORK Sorry i did not mention that i changed the slug 2x:
  23. Guido Schmechel commented on patch set 4 04/20/21, 10:37

    Reply

    Thanks! I'm trying to figure out if it's a consequence of these patches or if it's a fundamental problem. Maybe related: https://review.typo3.org/c/Packages/TYPO3.CMS/+/68818/
  1. Guido Schmechel commented on patch set 4 05/03/21, 21:41

    Reply

    Hi Jochen, i am stupid. The host problem is handled by a separate patch: https://review.typo3.org/c/Packages/TYPO3.CMS/+/61963 Thanks for the hint! To check the "multilang" redirects in this patch you have to changed the redirect host yourself in the redirect module.
  2. Jochen Roth commented on patch set 4 V +1 CR +1 05/06/21, 11:35

    It's working :-)
  3. Benni Mack commented on patch set 4 05/12/21, 08:52

    SlugService.php:184

    AFAICS we can also build this with 't3://page?uid=' . $targetPageRecord['uid'] . '&_language=' . $languageUid to ensure the link is built for a specific language.
  4. Stefan Bürk uploaded patch set 5 09/22/21, 19:51

  5. Stefan Bürk rebased onto patch set 6 09/22/21, 19:52

  6. Stefan Bürk commented on patch set 6 09/22/21, 20:01

    Rebased and incorperated $_language argument as mentioned by Benni. Adjusted functional tests to match language parameter in redirect records.

    SlugService.php:184 Reply

    Ack. Added as meantioned.
  7. Stefan Bürk uploaded patch set 7 09/22/21, 20:09

  8. core-ci voted on patch set 6 V +1 09/22/21, 20:24 Core CI is happy: https://gitlab.typo3.org/typo3/CI/cms/-/pipelines/17081

  9. core-ci voted on patch set 5 V -1 09/22/21, 20:27 Core CI is not happy: https://gitlab.typo3.org/typo3/CI/cms/-/pipelines/17080

  10. core-ci voted on patch set 7 V +1 09/22/21, 20:44 Core CI is happy: https://gitlab.typo3.org/typo3/CI/cms/-/pipelines/17083

  11. Stefan Bürk commented on patch set 7 CR -1 09/22/21, 20:55

    Not sure if the t3:// is correctly build, and as such if redirect links would be build correctly. Will check this further.
  12. Stefan Bürk commented on patch set 7 CR 0 09/23/21, 14:33

    Reply

    I tested this also. Even the "two changes in a row thing". There are 2 differen issue "noted" here + an additional one: 1. If site root is url, and languages only language folders like => '/en/' it is not the problem. But what is more an issue is, that currently in the backend when the auto-redirects are created (using db query) the RedirectCache will not be cleared/rebuild. As such the newly created auto-redirects are not in the cache, and as such can not be found/matched through the redirect middleware. As there is a patch pending to use the DataHandler instead of plain query which will trigger the cacheclear hook, this would be fixed that. So no need/blocking for this patch. See: https://review.typo3.org/c/Packages/TYPO3.CMS/+/71153 2. If language for a site have full domain instead of only path extension, this is not covered by this patch as already mentioned by Guido Schmechel. This should be adressed by the noted patch for that (as following patch). 3. Multi slug hanges setting old/original slug will create a further redirect, but this will end than in "endless redirect chain" as it is a circle then -> TOO MANY REDIRECTS error in browser. This is also not an issue of this patch and should be analysed and fixed in a seperate patch.
    Things done: - Rebased to get rid of merge-conflict (multi times) - Incorperated _language parameter for created t3:// link as mentioned by Benny - Checked t3:// link build/redirection manually in backend - Rechecked "multi-change" of slug field from a page (commented in the comment thread for that) In general I would say that that patch is now in a reviewable/mergable state, as addressed findings are not in the scope of this patch, as already existing and not introduced through it.

    Reply

    Okay, checked. It is okay how they are saved, and can be build correctly.
  13. Benni Mack commented on patch set 7 09/23/21, 14:48

    SlugService.php:176

    Sorry, my previous comment wasn't clear. I suggest to use LinkService->asString
  14. Stefan Bürk uploaded patch set 8 09/23/21, 15:30

  15. core-ci voted on patch set 8 V +1 09/23/21, 15:42 Core CI is happy: https://gitlab.typo3.org/typo3/CI/cms/-/pipelines/17113

  16. Stefan Bürk commented on patch set 8 V +1 CR +1 09/23/21, 15:44

    Reply

    Done

    Reply

    Done

    SlugService.php:176 Reply

    Right, thats better. Integrated use of LinkService->asString().

    SlugService.php:184 Reply

    Done
  17. Benni Mack commented on patch set 8 CR +1 09/23/21, 15:57

    very nice work!
  18. Wouter Wolters commented on patch set 8 09/23/21, 16:37

    SlugService.php:78

    why not add a typehint here directly for new code?
  19. Stefan Bürk commented on patch set 8 09/23/21, 16:46

    SlugService.php:78 Reply

    Ack. Means to remove the docbloc for the property then, or ? Note: Must be changed back for the backport than.
  20. Stefan Bürk uploaded patch set 9 09/23/21, 17:24

  21. core-ci voted on patch set 9 V +1 09/23/21, 17:37 Core CI is happy: https://gitlab.typo3.org/typo3/CI/cms/-/pipelines/17114

  22. Stefan Bürk commented on patch set 9 V +1 CR +1 09/23/21, 17:38

    SlugService.php:78 Reply Unresolved

    Done
  23. Guido Schmechel commented on patch set 9 09/24/21, 08:24

    Thank you for your optimisation :-)
  24. Benni Mack voted on patch set 9 V +2 CR +2 09/24/21, 09:08

  25. Benni Mack merged patch set 10 09/24/21, 09:08