rajalakshmys-27 opened a new issue, #2301: URL: https://github.com/apache/incubator-kie-issues/issues/2301
When opening a faulty BPMN file, making any modification (e.g. moving a node), and exporting the XML, the exported file contains a spurious `<bpmn:parsererror>` element at the top level. This element is injected by the browser's `DOMParser` when it encounters malformed or schema-invalid XML, but instead of being discarded, it is carried through the editor's internal model and serialized back into the exported file — corrupting it further on every save cycle. A faulty BPMN file : https://gist.githubusercontent.com/rajalakshmys-27/28e82fd3de60d656a28a0ab654401e32/raw/855f4fc030cd560d66e6b2cb7107134e1518c90b/parseerror.bpmn **Steps to reproduce** 1. Open a faulty BPMN file (e.g. one where `<bpmn:message>` is incorrectly nested inside `<bpmn:process>` instead of `<bpmn:definitions>`) 2. Make any modification, such as dragging the end node slightly to the right 3. Export the BPMN XML 4. Observe that the exported file contains a `<bpmn:parsererror>` element at the top level **Expected behavior** The `<bpmn:parsererror>` element is an internal parser artifact and should never appear in exported XML. The editor should either reject the malformed file with a clear error, or silently filter the element and export only the valid content. **Actual behavior** The `<bpmn:parsererror>` element is preserved in the exported XML, permanently corrupting the file on each edit-export cycle. -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: [email protected] For queries about this service, please contact Infrastructure at: [email protected] --------------------------------------------------------------------- To unsubscribe, e-mail: [email protected] For additional commands, e-mail: [email protected]
