jnunemaker/happymapper

LibXML::XML::Error: LibXML::XML::Error at :0.

azisaka opened this issue · 2 comments

I'm getting this error only when I use has_many or has_one method.

The code and xml is here: http://gist.github.com/105430

hi,
I'm also having a similar issue but only when using has_many. The error message in this case is 'Undefined namespace prefix. (LibXML::XML::Error)'. Works "fine" if I use 'element" or "has_one' but it gets me of course one element - which is not what i want. Here is the sample code and xml:

class Paragraph
include HappyMapper

tag 'Description'
namespace MyModule::NS
attribute :name, String, :tag => 'Name'
has_many :text, String, :tag => 'Text', :namespace => MyModule::NS, :attributes => {:Language => String}
end

<ns:Description Name="TITLE" xmlns:ns="http://www.example.org">
<ns:Text Language="EN">Title in English/ns:Text
<ns:Text Language="IT">Titolo in Italiano/ns:Text
/ns:Description

Closing due to staleness and the fact that the project is currently not being maintained.