subject.errors
"3:0: ERROR: Element '{http://datacite.org/schema/kernel-4}script': This element is not expected. Expected is one of ( {http://datacite.org/schema/kernel-4}identifier, {http://datacite.org/schema/kernel-4}creators, {http://datacite.org/schema/kernel-4}titles, {http://datacite.org/schema/kernel-4}publisher, {http://datacite.org/schema/kernel-4}publicationYear, {http://datacite.org/schema/kernel-4}resourceType, {http://datacite.org/schema/kernel-4}subjects, {http://datacite.org/schema/kernel-4}contributors, {http://datacite.org/schema/kernel-4}dates, {http://datacite.org/schema/kernel-4}language )."
subject.datacite_xml
*** TypeError Exception: no implicit conversion of String into Integer
nil
Describe the bug
bolognese Metadata objects generate invalid geoLocationPolygon DataCite XML.
Expected Behaviour
bolognese Metadata objects generated valid DataCite XML geoLocationPolygon metadata.
Current Behaviour
The
datacite_xml
attribute produces an erro, thevalid?
attribute is false, and theerrors
attribute contains errors.Steps to Reproduce
Run debugger at this line: https://github.com/datacite/bolognese/blob/7b3e8cd408cd141903765fb4904d33c5bba5ac42/spec/readers/datacite_reader_spec.rb#L1372
Context (Environment)
Screenshots
Further details
Proposal
Hypothesis
The geoLocationPolygon property seems to be handled inconsistently from the other attributes here: https://github.com/datacite/bolognese/blob/7b3e8cd408cd141903765fb4904d33c5bba5ac42/lib/bolognese/datacite_utils.rb#L377-L389 This seems to result in the
no implicit conversion of String into Integer
error.Possible Implementation