neos / neos-development-collection

The unified repository containing the Neos core packages, used for Neos development.
https://www.neos.io/
GNU General Public License v3.0
266 stars 222 forks source link

9.0 BUG: Make Neos.Neos independent of Neos.Ui #4951

Open mhsdesign opened 8 months ago

mhsdesign commented 8 months ago

We should not install the Neos Ui in ci runs as this leads to strong coupling between Neos.Neos and the Ui which already happened:

phpstan reports:

Error: Property Neos\Neos\Controller\Service\NodesController::$nodePropertyConverterService has unknown class Neos\Neos\Ui\Domain\Service\NodePropertyConverterService as its type.
Error: Call to method getPropertiesArray() on an unknown class Neos\Neos\Ui\Domain\Service\NodePropertyConverterService.
Error: Property Neos\Neos\Service\ContentElementWrappingService::$userLocaleService has unknown class Neos\Neos\Ui\Domain\Service\UserLocaleService as its type.
Error: Property Neos\Neos\Service\ContentElementWrappingService::$nodeInfoHelper has unknown class Neos\Neos\Ui\Fusion\Helper\NodeInfoHelper as its type.
Error: Call to method switchToUILocale() on an unknown class Neos\Neos\Ui\Domain\Service\UserLocaleService.
Error: Call to method renderNodeWithPropertiesAndChildrenInformation() on an unknown class Neos\Neos\Ui\Fusion\Helper\NodeInfoHelper.
Error: Call to method switchToUILocale() on an unknown class Neos\Neos\Ui\Domain\Service\UserLocaleService.

And Neos will not even boot without the Ui installed:

The object "Neos\Neos\Ui\Domain\Service\NodePropertyConverterService" which was specified as a property in the object configuration of object "Neos\Neos\Controller\Service\NodesController" (automatically registered class) does not exist.

As we use the development distribution which includes the ui we could either remove it or use a custom test distribution

composer remove --no-update neos/neos-ui neos/neos-ui-compiled

having the ui installed leads to 🐔 🥚 problems, for example when the api changes.

mhsdesign commented 7 months ago

Also the unit tests are executed of the Neos Ui as well due the config in Build/BuildEssentials/PhpUnit/UnitTests.xml to run every test.

mhsdesign commented 5 months ago

See also https://discuss.neos.io/t/rfc-future-of-the-neos-package-architecture-neos-neos-in-particular/6593/15