Review main Merged

80434[TASK] Remove TCA MM_hasUidField

Christian Kuhn CR +2 V +2 Normal +156 −33 updated 08/08/23, 10:16

Commit message

MM tables only need a uid column when "multiple" is true.

With primary keys finally being properly set on MM
relations without "multiple", we can remove "MM_hasUidField"
and derive the information whether a uid column is needed
from "multiple" flag, which obsoletes "MM_hasUidField".

Review

  • Code review CR +2 Done
    • Benni Mack +2
    • Oliver Klee +1
  • Verified V +2 Done
    • Benni Mack +2
    • Oliver Klee +1
    • core-ci +1 CI

Issues 2

Files 10

Review log 1318

  1. Christian Kuhn uploaded patch set 1 08/07/23, 13:42

  2. core-ci voted on patch set 1 V -1 08/07/23, 13:54 Core CI is not happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/45192

  3. Christian Kuhn uploaded patch set 2 V -1 08/07/23, 14:43

  4. core-ci voted on patch set 2 V +1 08/07/23, 14:50 Core CI is happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/45194

  5. Christian Kuhn uploaded patch set 3 V +1 08/08/23, 07:22

  6. core-ci voted on patch set 3 V +1 08/08/23, 07:29 Core CI is happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/45220

  7. Christian Kuhn uploaded patch set 4 V +1 08/08/23, 08:00

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

  9. Oliver Klee commented on patch set 4 V +1 08/08/23, 08:26

    Awesome! Added some comments on smaller things.

    RelationHandler.php:128

    If we're introducing a new property anyway (in place of the old property), should we directly make it private?

    DefaultTcaSchema.php:616

    I like this renaming! It makes things more clear.

    TcaMigration.php:1471

    Do we still need the `isset` if we have the fallback for the `is_array`?
  10. Benni Mack commented on patch set 4 08/08/23, 08:53

    RelationHandler.php:128 Reply

    why?

    TcaMigration.php:1471 Reply

    agree
  11. Oliver Klee commented on patch set 4 08/08/23, 09:12

    RelationHandler.php:128 Reply

    I talked with Lolli about this (in general) at T3DD23, and we both were inclined to use `private` more and only expose via `protected` to subclasses if we explicitly wanted to make them (subclass) API (instead of the other way around, where everything is `protected`, which automatically makes many refactorings breaking).
  12. Christian Kuhn commented on patch set 4 08/08/23, 09:28

    RelationHandler.php:128 Reply

    I'd keep it like that for now - I'd rather refactor the whole class later to remove most of the properties anyways: There is no point in deriving all this state from the incoming start() $config array.

    TcaMigration.php:1471 Reply

    Done
  13. Christian Kuhn uploaded patch set 5 V +1 08/08/23, 09:29

  14. core-ci voted on patch set 5 V +1 08/08/23, 09:36 Core CI is happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/45229

  15. Oliver Klee commented on patch set 5 V +1 CR +1 08/08/23, 09:42

    RelationHandler.php:128 Reply

    Ack
  16. Benni Mack commented on patch set 5 08/08/23, 10:16

    RelationHandler.php:128 Reply

    I disagree on that topic. By using private but people would need a workaround in their extension they would need to copy more and more code in to their XCLASS. XCLASS, protected properties (except on Abstract methods), nor using "@internal" classes nor patching via composer patches are neither part of the bw/compat promise, but private makes lives easier if people would need to adapt - but then "they are on their own"
  17. Benni Mack voted on patch set 5 V +2 CR +2 08/08/23, 10:16

  18. Benni Mack merged patch set 6 08/08/23, 10:16