You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
When importing site contents from a Sites.xml file via ./flow site:import, the following exception occurs:
Exception #1300360480 in line 99 of [...]/Framework/Neos.Flow/Classes/ObjectManagement/DependencyInjection/DependencyProxy.php: Error: During import an exception occurred: "Could not convert PHP value of type DateTime to type date_immutable. Expected one of the following types: null, DateTimeImmutable".
When the Sites.xml contains <creationDateTime/> or <lastModificationDateTime/> elements, the property mapper is instructed to convert them to DateTime rather than DateTimeImmutable objects.
Expected Behavior
The importer should convert <creationDateTime/> , <lastModificationDateTime/> and any other date/time to \DateTimeImmuable rather than \DateTime.
Steps To Reproduce
Run ./flow site:import on a site export (presumably one that has been done with Neos 8.3 or earlier) in a Neos 8.4 setup. Make sure doctrine/dbal@3.* is installed. The error should show up in that environment.
Environment
- Flow: 8.4
- Neos: 8.4
- PHP: 8.2
I suspect the error didn't show prior to Neos/Flow 8.4, because of 8.4 pulling in `doctrine/dbal@3.*` rather than `doctrine/dbal@2.*`.
Anything else?
No response
The text was updated successfully, but these errors were encountered:
Is there an existing issue for this?
Current Behavior
When importing site contents from a
Sites.xml
file via./flow site:import
, the following exception occurs:This is due to
neos-development-collection/Neos.ContentRepository/Classes/Domain/Service/ImportExport/NodeImportService.php
Line 324 in ef53627
When the
Sites.xml
contains<creationDateTime/>
or<lastModificationDateTime/>
elements, the property mapper is instructed to convert them toDateTime
rather thanDateTimeImmutable
objects.Expected Behavior
The importer should convert
<creationDateTime/>
,<lastModificationDateTime/>
and any other date/time to\DateTimeImmuable
rather than\DateTime
.Steps To Reproduce
Run
./flow site:import
on a site export (presumably one that has been done with Neos 8.3 or earlier) in a Neos 8.4 setup. Make suredoctrine/dbal@3.*
is installed. The error should show up in that environment.Environment
Anything else?
No response
The text was updated successfully, but these errors were encountered: