Review main Merged

88200[BUGFIX] Fix race condition on creating select tree elements

Patrick Schriner CR +2 V +2 Easy +10 −3 updated 03/21/25, 08:31

Commit message

On slow internet connections the javascript creating the element can be
executed before the actual required data is available. Deferring the
initialization to the ready state prevents that race condition.

Review

  • Code review CR +2 Done
    • Benjamin Franzke +2
    • Andreas Nedbal +1
    • Christian Rath-Ulrich +1
  • Verified V +2 Done
    • Benjamin Franzke +2
    • Andreas Nedbal +1
    • Christian Rath-Ulrich +1
    • core-ci +1 CI

Issues 1

Files 2

Review log 1116

  1. Patrick Schriner uploaded patch set 1 02/12/25, 17:17

  2. Garvin Hicking updated the commit message in patch set 2 02/12/25, 17:21

  3. core-ci voted on patch set 1 V +1 02/12/25, 17:26 Core CI is happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/74060

  4. core-ci voted on patch set 2 V +1 02/12/25, 17:27 Core CI is happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/74061

  5. Andreas Nedbal rebased onto patch set 3 V +1 03/07/25, 12:56

    The following files contain Git conflicts: * Build/Sources/TypeScript/backend/form-engine/element/select-tree-element.ts
  6. core-ci voted on patch set 3 V -1 03/07/25, 13:02 Core CI is not happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/75300

  7. Andreas Nedbal uploaded patch set 4 03/07/25, 13:17

    Copied Votes: * Verified-1 (copy condition: "**changekind:NO_CHANGE**")
  8. Andreas Nedbal uploaded patch set 5 V -1 03/07/25, 13:18

  9. Andreas Nedbal marked it ready for review 03/07/25, 13:19

  10. core-ci voted on patch set 4 V -1 03/07/25, 13:24 Core CI is not happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/75301

  11. core-ci voted on patch set 5 V +1 03/07/25, 13:25 Core CI is happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/75302

  12. Andreas Nedbal voted on patch set 5 CR +1 V +1 03/07/25, 13:28

  13. Christian Rath-Ulrich voted on patch set 5 CR +1 V +1 03/19/25, 13:17

  14. Benjamin Franzke commented on patch set 5 03/21/25, 07:53

    select-tree-element.ts:35

    For readability I'd prefer: ``` private async initialize(treeWrapperId: string, treeRecordFieldId: string, onFieldChangeItems?: OnFieldChangeItem[]): Promise<void> { await DocumentService.ready(); … } ``` but we still have a dozen places that use then-closures as well, so I don't care too much to change.
  15. Benjamin Franzke voted on patch set 5 CR +2 V +2 03/21/25, 07:58

  16. Benjamin Franzke merged patch set 6 03/21/25, 08:31