Review main Merged

69174[FEATURE] Consider all Composer installed extensions as active

Helmut Hummel CR +2 V +2 Expert +1249 −123 updated 08/27/21, 15:16

Commit message

The idea of this change is, that when using Composer,
all TYPO3 extensions, that are part of the Composer
installation, should be considered as active and there
is no need whatsoever to install code of an
extension with Composer (and making all its classes
available), but not wanting the extension to interact with
TYPO3 API.

Therefore with this change, all TYPO3 extensions installed
with Composer are considered to be active (and therefore can
and will interact with TYPO3 API).

Additionally, since the list of active extension is known
during Composer installation, a persistent artefact is
created at this point, which represents the final state
of TYPO3 extension packages for the PackageManager,
making both, the PackageStates.php file and the
PackageManager cache obsolete for Composer managed
TYPO3 installations.

Note any extension present in the typo3conf/ext folder,
but not installed by Composer, will still
be considered and marked as part of TYPO3 packages when
doing a "composer install". The only requirement here is,
that such extensions need a composer.json file nonetheless.
Note this behaviour is deprecated and will be removed
with TYPO3 12.

Additionally the extension manager UI is adapted to
not allow changing the active state of extensions anymore.
Respectively the commands "extension:activate" and
"extension:deactivate" are disabled in Composer managed
systems as well.

A new cli command "extension:setup" is introduced, which
supersedes both, the extension manager UI as well as the
activate/deactivate commands. It performs all steps that
were done before, except changing the active state of an
extension.

With cli command "extension:setup" ALL extensions are
set up in terms of database schema changes, static data
import, distribution files imports, etc.

Last but not least, any installed Composer package, that
defines an extra.typo3/cms section in their composer.json file,
but is not of type "typo3-cms-extension" at the same time,
will be considered for TYPO3 and will have full access
to TYPO3 API. It has to be noted though that such packages
can not deliver public resources. This remains exclusive for
TYPO3 extensions for now.

Review

  • Code review CR +2 Done
    • Helmut Hummel +2
    • Benjamin Franzke +1
    • Jochen Roth +1
    • Christian Kuhn +1
  • Verified V +2 Done
    • Helmut Hummel +2
    • Benjamin Franzke +1
    • Jochen Roth +1
    • Christian Kuhn +1
    • core-ci +1 CI

Issues 1

Files 33

Show 13 more files

Review log 4372

Show 2647 earlier messages
  1. Helmut Hummel uploaded patch set 1 05/18/21, 11:51

  2. core-ci voted on patch set 1 V -1 05/18/21, 11:53 Core CI is not happy: https://gitlab.typo3.org/TYPO3/CI/cms/-/pipelines/11616

  3. Helmut Hummel uploaded patch set 2 05/19/21, 10:03

  4. core-ci voted on patch set 2 V -1 05/19/21, 10:04 Core CI is not happy: https://gitlab.typo3.org/TYPO3/CI/cms/-/pipelines/11667

  5. Helmut Hummel uploaded patch set 3 08/24/21, 23:04

  6. core-ci voted on patch set 3 V -1 08/24/21, 23:07 Core CI is not happy: https://gitlab.typo3.org/typo3/CI/cms/-/pipelines/15548

  7. Benni Mack uploaded patch set 4 08/25/21, 15:12

  8. core-ci voted on patch set 4 V -1 08/25/21, 15:17 Core CI is not happy: https://gitlab.typo3.org/typo3/CI/cms/-/pipelines/15609

  9. Helmut Hummel uploaded patch set 5 08/25/21, 15:20

  10. core-ci voted on patch set 5 V -1 08/25/21, 15:23 Core CI is not happy: https://gitlab.typo3.org/typo3/CI/cms/-/pipelines/15610

  11. Helmut Hummel uploaded patch set 6 08/25/21, 16:09

  12. Helmut Hummel uploaded patch set 7 08/25/21, 16:10

  13. core-ci voted on patch set 6 V -1 08/25/21, 16:13 Core CI is not happy: https://gitlab.typo3.org/typo3/CI/cms/-/pipelines/15612

  14. Helmut Hummel uploaded patch set 8 08/25/21, 16:24

  15. core-ci voted on patch set 7 V -1 08/25/21, 16:26 Core CI is not happy: https://gitlab.typo3.org/typo3/CI/cms/-/pipelines/15613

  16. core-ci voted on patch set 8 V -1 08/25/21, 16:38 Core CI is not happy: https://gitlab.typo3.org/typo3/CI/cms/-/pipelines/15615

  17. Helmut Hummel uploaded patch set 9 08/25/21, 20:45

  18. core-ci voted on patch set 9 V -1 08/25/21, 20:58 Core CI is not happy: https://gitlab.typo3.org/typo3/CI/cms/-/pipelines/15629

  19. Helmut Hummel uploaded patch set 10 08/25/21, 21:13

  20. core-ci voted on patch set 10 V -1 08/25/21, 21:34 Core CI is not happy: https://gitlab.typo3.org/typo3/CI/cms/-/pipelines/15630

  21. Helmut Hummel uploaded patch set 11 08/25/21, 21:46

  22. Helmut Hummel uploaded patch set 12 08/25/21, 22:07

  23. core-ci voted on patch set 12 V -1 08/25/21, 22:10 Core CI is not happy: https://gitlab.typo3.org/typo3/CI/cms/-/pipelines/15633

  24. Helmut Hummel uploaded patch set 13 08/25/21, 22:11

  25. core-ci voted on patch set 11 V -1 08/25/21, 22:11 Core CI is not happy: https://gitlab.typo3.org/typo3/CI/cms/-/pipelines/15632

  26. core-ci voted on patch set 13 V -1 08/25/21, 22:31 Core CI is not happy: https://gitlab.typo3.org/typo3/CI/cms/-/pipelines/15634

  27. Helmut Hummel uploaded patch set 14 08/25/21, 22:31

  28. core-ci voted on patch set 14 V +1 08/25/21, 22:44 Core CI is happy: https://gitlab.typo3.org/typo3/CI/cms/-/pipelines/15635

  29. Helmut Hummel uploaded patch set 15 08/25/21, 23:24

  30. core-ci voted on patch set 15 V +1 08/25/21, 23:38 Core CI is happy: https://gitlab.typo3.org/typo3/CI/cms/-/pipelines/15639

  31. Simon Gilli commented on patch set 15 08/26/21, 01:35

    Nice one!

    PackageInterface.php:23

    Is there a reason not allowing dots as done by composer? See also https://github.com/composer/composer/blob/master/src/Composer/Command/InitCommand.php#L100
  32. Helmut Hummel commented on patch set 15 08/26/21, 11:15

    PackageInterface.php:23 Reply

    no. in fact we should copy the regex from composer sources to here
  33. Benjamin Franzke uploaded patch set 16 08/26/21, 12:41

  34. Benjamin Franzke commented on patch set 16 08/26/21, 12:41

    PackageInterface.php:23 Reply

    Done

    Services.yaml:18

    We can use the existing `hidden` property using: hidden: "%env(TYPO3:isComposerMode)%" env(TYPO:…) is resolved by TYPO3\CMS\Core\DependencyInjection\EnvVarProcessor from the Environment global. Also see: https://docs.typo3.org/c/typo3/cms-core/11.1/en-us/Changelog/10.2/Important-89764-IncompatibleEnvironmentRelatedDependencyInjectionServicesHaveBeenRemoved.html
  35. Helmut Hummel commented on patch set 16 08/26/21, 12:46

    Services.yaml:18 Reply

    Very cool, thanks!
  36. core-ci voted on patch set 16 V +1 08/26/21, 13:01 Core CI is happy: https://gitlab.typo3.org/typo3/CI/cms/-/pipelines/15672

  37. Helmut Hummel uploaded patch set 17 08/26/21, 13:01

  38. core-ci voted on patch set 17 V +1 08/26/21, 13:22 Core CI is happy: https://gitlab.typo3.org/typo3/CI/cms/-/pipelines/15674

  39. Helmut Hummel uploaded patch set 18 08/26/21, 14:07

  40. core-ci voted on patch set 18 V +1 08/26/21, 14:29 Core CI is happy: https://gitlab.typo3.org/typo3/CI/cms/-/pipelines/15678

  41. Helmut Hummel uploaded patch set 19 08/27/21, 08:17

  42. core-ci voted on patch set 19 V -1 08/27/21, 08:36 Core CI is not happy: https://gitlab.typo3.org/typo3/CI/cms/-/pipelines/15706

  43. Helmut Hummel uploaded patch set 20 08/27/21, 08:40

  44. core-ci voted on patch set 20 V -1 08/27/21, 08:54 Core CI is not happy: https://gitlab.typo3.org/typo3/CI/cms/-/pipelines/15708

  45. Helmut Hummel uploaded patch set 21 08/27/21, 08:56

  46. core-ci voted on patch set 21 V +1 08/27/21, 09:14 Core CI is happy: https://gitlab.typo3.org/typo3/CI/cms/-/pipelines/15709

  47. Helmut Hummel commented on patch set 21 CR -2 08/27/21, 10:05

    The last set is broken. will fix asap
  1. Helmut Hummel uploaded patch set 22 08/27/21, 10:32

  2. Helmut Hummel uploaded patch set 23 08/27/21, 10:49

  3. core-ci voted on patch set 22 V -1 08/27/21, 10:53 Core CI is not happy: https://gitlab.typo3.org/typo3/CI/cms/-/pipelines/15714

  4. core-ci voted on patch set 23 V +1 08/27/21, 11:01 Core CI is happy: https://gitlab.typo3.org/typo3/CI/cms/-/pipelines/15715

  5. Helmut Hummel voted on patch set 23 CR 0 08/27/21, 11:02

  6. Benjamin Franzke uploaded patch set 24 08/27/21, 12:05

  7. core-ci voted on patch set 24 V +1 08/27/21, 12:24 Core CI is happy: https://gitlab.typo3.org/typo3/CI/cms/-/pipelines/15721

  8. Christian Kuhn commented on patch set 24 CR -1 08/27/21, 12:24

    working on it.
  9. Christian Kuhn commented on patch set 24 08/27/21, 12:32

    composer.dist.json:56

    we'll use that file in a CI job to test composer update and composer update --pefer-lowest later ... that'll be a dedicated patch, though.
  10. Christian Kuhn uploaded patch set 25 08/27/21, 14:03

  11. Christian Kuhn commented on patch set 25 CR -1 08/27/21, 14:15

    helmut working on it.
  12. Helmut Hummel uploaded patch set 26 08/27/21, 14:16

  13. core-ci voted on patch set 25 V -1 08/27/21, 14:19 Core CI is not happy: https://gitlab.typo3.org/typo3/CI/cms/-/pipelines/15728

  14. Christian Kuhn commented on patch set 26 CR -1 08/27/21, 14:20

    working on it.
  15. core-ci voted on patch set 25 V +1 08/27/21, 14:27 Core CI is happy: https://gitlab.typo3.org/typo3/CI/cms/-/pipelines/15728

  16. core-ci voted on patch set 26 V +1 08/27/21, 14:28 Core CI is happy: https://gitlab.typo3.org/typo3/CI/cms/-/pipelines/15729

  17. Helmut Hummel uploaded patch set 27 08/27/21, 14:41

  18. Christian Kuhn uploaded patch set 28 08/27/21, 15:00

  19. core-ci voted on patch set 27 V -1 08/27/21, 15:01 Core CI is not happy: https://gitlab.typo3.org/typo3/CI/cms/-/pipelines/15731

  20. Benjamin Franzke voted on patch set 28 V +1 CR +1 08/27/21, 15:03

  21. Jochen Roth voted on patch set 28 V +1 CR +1 08/27/21, 15:07

  22. Christian Kuhn voted on patch set 28 V +1 CR +1 08/27/21, 15:10

  23. Helmut Hummel commented on patch set 28 V +2 CR +2 08/27/21, 15:15

    Thanks a bunch to everybody involved!
  24. core-ci voted on patch set 28 V +1 08/27/21, 15:16 Core CI is happy: https://gitlab.typo3.org/typo3/CI/cms/-/pipelines/15733

  25. Helmut Hummel merged patch set 29 08/27/21, 15:16