rajalakshmys-27 opened a new pull request, #3610:
URL: https://github.com/apache/incubator-kie-tools/pull/3610

   After the `xml-parser-ts` fix (#3570) that filters `<parsererror>` elements 
and throws on malformed XML was merged (as part of the broader BPMN/DMN/SCESIM 
parser error fix), the SCESIM editor Storybook stories broke in local 
development.
   
   **Root Cause**
   
   The Storybook stories for the SCESIM editor had two latent bugs that were 
always present but previously silent:
   
   1. **Malformed XML in the SIMPLE model** — a tag like `<text>Input &gt; 
18<text>` was missing the `/` in its closing tag, making it invalid XML.
   2. **DevWebApp story passing a filename string instead of XML content** — 
the story was calling `getMarshaller(emptyFileName).parser.parse()` where 
`emptyFileName` is `"Untitled.scesim"`, a filename string, instead of actual 
XML content. `getMarshaller()` expects XML, so the DOMParser tried to parse the 
filename as XML and silently failed.
   
   These bugs never surfaced before because the browser's `DOMParser` was 
producing empty `<parsererror>` elements for these inputs, and the old code 
only threw when `hasRealError` was true (i.e., the parsererror element had 
non-empty text content). The stricter error handling introduced in the parser 
fix now correctly detects and throws on these malformed inputs.


-- 
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]

Reply via email to