Closed vadimt closed 14 years ago
I'm curious - What's the use case or this? Do you actually have an application with a namespace that contains quotes?
I'll look into the issue, but likely the problem happens at the xml-parser level. Off the top of my head, I'm actually unsure if the above is valid xml.
This is actually xml that is coming back from an external application API I am integrating with. I wasn't sure if it was valid either, but http://www.w3schools.com/Xml/xml_attributes.asp says that it's ok.
I cannot replicate this issue in any of the XML parsers. What ruby version and XML parser are you using? I tested both Ruby 1.8.7 and 1.9.2 using this spec file:
Thanks for looking into this
Ruby 1.8.7 patchlevel 174 Nokogiri 1.4.3.1 Handsoap 1.1.7
The error occurred when running tests using VCR with webmock, changing the mock to remove the single quotes did not throw the error.
I replicated the error somewhat and traced it back to libxml2. You can try using xmllint which comes with libxml2 to see it throw an error on the namespace with quotes. I tried parsing it with REXML and that worked a bit better. Try and set Handsoap.xml_query_driver = :rexml and see if that works better for you.
Right on, thank you.
The following response throws a 'The response is not a valid SOAP envelope' error due to the single quotes in xmlns:ns1="'daily'_type_quota"
<?xml version="1.0" encoding="UTF-8"?>