prowide-iso20022 icon indicating copy to clipboard operation
prowide-iso20022 copied to clipboard

Parsing issue with MX message of type xsys.003.001.01

Open john236 opened this issue 3 years ago • 3 comments

My issue sounds similar to https://github.com/prowide/prowide-iso20022/issues/39 but is about the xsys.003.001.01 message type.

The ThirdPartyRefusalReason element is of type SwAny but when I try to parse a message with a 4 character string in that element, for example: <Sw:ThirdPartyRefusalReason>ABCD</Sw:ThirdPartyRefusalReason> then SwAny.any is null.

john236 avatar Jan 17 '22 06:01 john236

I see. We need to find general solution for all Any types in the parser.

zubri avatar Feb 23 '22 22:02 zubri

fyi, Swift have now changed the SwAny type so it must have a child element. For example:

<Sw:ThirdPartyRefusalReason>
  <Sw:Cd>ABCD</Sw:Cd>
</Sw:ThirdPartyRefusalReason>

john236 avatar Feb 25 '22 04:02 john236

Test case and a few exploration approaches have been pushed to: https://github.com/prowide/prowide-iso20022/pull/48

XmlAnyElement is expected to be parsed into a generic Element node.

The root cause is probably in our NamespaceAndElementFilter and MxReadImpl classes. But could not find a solution to fit al scenarios yet.

zubri avatar May 25 '22 16:05 zubri