Bug #90239
closedORM in Extbase broken for ObjectStorage
0%
Description
When adding v10 compatibility to an Extbase extension, I'm currently struggling with the following error message:
Cannot create empty instance of the class "TYPO3\CMS\Extbase\Persistence\ObjectStorage" because it does not implement the TYPO3\CMS\Extbase\DomainObject\DomainObjectInterface.
The error occurs in the current TYPO3 master, as soon as getters/setters for ObjectStorage
properties are added to a domain model. I tried several different annotations for the ObjectStorage
property, but all result in different error messages (mostly in relation to ObjectStorage
as shown in the example below)
"\TYPO3\CMS\Extbase\Persistence\ObjectStorage<\TYPO3\CMS\Extbase\Domain\Model\Category>" is not a valid Fqsen.
I created a very simple test extension to reproduce the problem: https://github.com/derhansen/extbase_test
How to reproduce:- Install extension
- Create a record of type "test" on a page (Add title and select at least one category)
- Add plugin to page and select storage page where record was created
- Error message is shown in FE when page with plugin is called
Updated by Torben Hansen almost 5 years ago
It seems I was just too tired and forgot to update composer dependencies of my local TYPO3 master... doh!
Please close this ticket.
Updated by Nikita Hovratov 12 months ago
If someone should stumble across this as me: I migrated a classic mode v10 project to composer and got this error.
You should perform composer update --prefer-lowest
here, so you get the exact same vendor versions as the packaged classic mode TYPO3.
Seems there is some package, which I couldn't pin down, that broke in a newer version.