Forum

AsXElement bug

fixed-for-45beta34.1
devvvv

#1

No Return is allowed in any string of the patch in order to make AsXElement working with PatchAlias.

am I missing something?

tnx

AsXElement_bug.v4p (10.1 kB)


#2

It’s because the backslashes of the dtd-path are escaped like this %5C (and validation was set to none). When setting _Validation _to dtd on AsXElement (XML) TTY throws the following error:

00:08:44 ERR : System.UriFormatException in System: Invalid URI: A Dos path must be rooted, for example, 'c:\'.

Stacktrace:
   at System.Uri.CreateThis(String uri, Boolean dontEscape, UriKind uriKind)
   at System.Uri..ctor(String uriString, UriKind uriKind)
   at System.Xml.XmlResolver.ResolveUri(Uri baseUri, String relativeUri)
   at System.Xml.XmlUrlResolver.ResolveUri(Uri baseUri, String relativeUri)
   at System.Xml.XmlTextReaderImpl.PushExternalEntityOrSubset(String publicId, String systemId, Uri baseUri, String entityName)
   at System.Xml.XmlTextReaderImpl.DtdParserProxy_PushExternalSubset(String systemId, String publicId)
   at System.Xml.XmlTextReaderImpl.DtdParserProxy.System.Xml.IDtdParserAdapter.PushExternalSubset(String systemId, String publicId)
   at System.Xml.DtdParser.ParseExternalSubset()
   at System.Xml.DtdParser.ParseInDocumentDtd(Boolean saveInternalSubset)
   at System.Xml.DtdParser.Parse(Boolean saveInternalSubset)
   at System.Xml.DtdParser.System.Xml.IDtdParser.ParseInternalDtd(IDtdParserAdapter adapter, Boolean saveInternalSubset)
   at System.Xml.XmlTextReaderImpl.ParseDtd()
   at System.Xml.XmlTextReaderImpl.ParseDoctypeDecl()
   at System.Xml.XmlTextReaderImpl.ParseDocumentContent()
   at System.Xml.XmlTextReaderImpl.Read()
   at System.Xml.XmlValidatingReaderImpl.Read()
   at System.Xml.Linq.XDocument.Load(XmlReader reader, LoadOptions options)
   at VVVV.Nodes.XML.XMLNodes.AsDocument(String xml, Validation validation)
   at VVVV.Nodes.XML.XMLAsElementNode.Evaluate(Int32 spreadMax)

Substituting 5%C with “” makes it work.

AsXElement_bug.v4p (11.5 kB)


#3

thanks for pointing this out. fixed in latest alphas.