Details
-
Bug
-
Resolution: Duplicate
-
High
-
1.13.1, 2.0.2, 1.7.7
-
ezsystems/ezplatform-xmltext-fieldtype version 1.5.1
Description
Currently, while upgrading from eZ Publish 5.4 to eZ Platform, if there were some <link> tags with ID parameter filled out in the XmlText FieldType, then running the migration script from https://github.com/ezsystems/ezplatform-xmltext-fieldtype (ezxmltext:convert-to-richtext) results in the following error:
[Symfony\Component\Debug\Exception\ContextErrorException] Warning: DOMDocument::loadXML(): xml:id : attribute value 45678 is not an NCName in Entity, line: 2 Exception trace: () at xxx\vendor\ezsystems\ezplatform-xmltext-fieldtype\bundle\Command\ConvertXmlTextToRichTextCommand.php:259 Symfony\Component\Debug\ErrorHandler->handleError() at n/a:n/a DOMDocument->loadXML() at xxx\vendor\ezsystems\ezplatform-xmltext-fieldtype\bundle\Command\ConvertXmlTextToRichTextCommand.php:259 EzSystems\EzPlatformXmlTextFieldTypeBundle\Command\ConvertXmlTextToRichTextCommand->convert() at xxx\vendor\ezsystems\ezplatform-xmltext-fieldtype\bundle\Command\ConvertXmlTextToRichTextCommand.php:188 EzSystems\EzPlatformXmlTextFieldTypeBundle\Command\ConvertXmlTextToRichTextCommand->convertFields() at xxx\vendor\ezsystems\ezplatform-xmltext-fieldtype\bundle\Command\ConvertXmlTextToRichTextCommand.php:93 EzSystems\EzPlatformXmlTextFieldTypeBundle\Command\ConvertXmlTextToRichTextCommand->execute() at xxx\vendor\symfony\symfony\src\Symfony\Component\Console\Command\Command.php:242 Symfony\Component\Console\Command\Command->run() at xxx\vendor\symfony\symfony\src\Symfony\Component\Console\Application.php:861 Symfony\Component\Console\Application->doRunCommand() at xxx\vendor\symfony\symfony\src\Symfony\Component\Console\Application.php:193 Symfony\Component\Console\Application->doRun() at xxx\vendor\symfony\symfony\src\Symfony\Bundle\FrameworkBundle\Console\Application.php:84 Symfony\Bundle\FrameworkBundle\Console\Application->doRun() at xxx\vendor\symfony\symfony\src\Symfony\Component\Console\Application.php:117 Symfony\Component\Console\Application->run() at xxx\app\console:29
The migration stops at this Field.
In the database, the fragment that causes the error looks like the following:
<link xhtml:id="123" url_id="32">Test</link>
Steps to reproduce
- Create a new eZ Publish installation.
- Create a new Article Content Object.
- Inside of one of the Article's Rich Text Fields, write any text (for example "Test"). Select this text and click "Insert/edit link" option. There, select "Https" option and insert "https://example.com" below it. Finally, put "123" into the ID parameter and click "OK". Publish the Article.
- Migrate to eZ Platform using this guide: https://doc.ezplatform.com/en/latest/migrating/migrating_from_ez_publish_platform/.
- Migrate XmlText to RichText (https://doc.ezplatform.com/en/latest/migrating/migrating_from_ez_publish_platform/#321-migrate-xmltext-content-to-richtext).
- During the execution of ezxmltext:convert-to-richtext command, you will be presented with the error described above.
Attachments
Issue Links
- duplicates
-
EZP-29289 Migrating ezxmltext with invalid name or id attributes
- Closed