[Archivesspace_Users_Group] id=0 error on EAD XML import

Andrew Morrison andrew.morrison at bodleian.ox.ac.uk
Thu Oct 20 04:35:26 EDT 2022


Don't be surprised if the import fails again, with the same message but 
for a subrecord, or with a different message. That is because the 
ArchivesSpace EAD importer uses a SAX parser method 
(https://en.wikipedia.org/wiki/Simple_API_for_XML) to read the XML, not 
a DOM (Document Object Model) method. The former is faster and uses less 
memory, but cannot scan an entire XML file for issues and report back 
with a list of things to fix, as the latter would. That is why many 
people use a pre-import validation step to find most of the issues that 
might occur, without the laborious process of creating an import job, 
waiting for it to fail, then re-running.

Harvard have made theirs into a web service which you might find useful:

https://eadchecker.lib.harvard.edu/

I think it is fairly generic (unlike a similar validation script used 
here which imposes editorial restrictions as well.)

Andrew.


On 19/10/2022 22:19, Custer, Mark wrote:
>
> Sarah,
>
> I suspect that your EAD file is missing an archdesc/did/unitid field. 
> This is where ArchivesSpace pulls information to create its Identifier 
> field for the new Resource (see the attached screenshot), which is a 
> required element.
>
> If you add something there, then I believe it should work.  Here’s an 
> example from one of our EAD files, 
> https://github.com/YaleArchivesSpace/Archives-at-Yale-EAD3/blob/master/brbl-ead/1000.xml#L80 
> (this file is EAD3, but the archdesc/did/unitid construction looks the 
> same in EAD2002).
>
> As for why you don’t have one in your file, I expect that’s because 
> the call number is stored in a related MARC holdings record, or 
> somewhere else that’s not being migrated as part of the MARC XML to 
> EAD conversion (e.g., an 099 field).
>
> Mark
>
> *From: *archivesspace_users_group-bounces at lyralists.lyrasis.org 
> <archivesspace_users_group-bounces at lyralists.lyrasis.org> on behalf of 
> Newhouse, Sarah <snewhouse at sciencehistory.org>
> *Date: *Wednesday, October 19, 2022 at 4:33 PM
> *To: *Archivesspace Users Group 
> <archivesspace_users_group at lyralists.lyrasis.org>
> *Subject: *[Archivesspace_Users_Group] id=0 error on EAD XML import
>
> Hi all,
>
> I’m trying to import a test EAD file that I transformed from MARC XML 
> as a trial run for doing this in batches. I knew it would be janky, 
> but I can’t narrow in on the specific form of the jank here. When I 
> import I get the error below (it’s long, apologies). My two best 
> guesses are
> a) ASpace is missing something in each XML element needed to create an 
> ID in every one of the JSON fields below?  (which appears to be the 
> entire resource record)
> b) there’s something missing from the <ead> element in the XML file? 
> (which there shouldn’t be – I copied it in manually from an ASpace EAD 
> export)
>
> I know this id_0 error is vague and has confused other people before, 
> but I couldn’t find enough information to help me narrow in on the 
> specific issue is here.
>
> Thanks!
>
> ********************************************************
>
> The following errors were found:
>          id_0 : Property is required but was missing
>   
>   
>   For JSONModel(:resource):
>   #<JSONModel(:resource) {"jsonmodel_type"=>"resource", "external_ids"=>[], "subjects"=>[{"ref"=>"/subjects/import_e9b747a7-9d78-4dac-b424-51ff0dabc301"}, {"ref"=>"/subjects/import_b6e2afcf-be53-480e-981d-cc359ca31719"}, {"ref"=>"/subjects/import_24b83fea-3081-4770-a77b-a2b3e870d75a"}, {"ref"=>"/subjects/import_b5b565e8-4cf4-44ee-bef4-bb5d80ea6788"}, {"ref"=>"/subjects/import_30ccd3c2-8d46-4373-a803-9ff8f7ad3d7a"}, {"ref"=>"/subjects/import_68e70347-cfb7-4ccb-b1f9-2349ae2a3448"}, {"ref"=>"/subjects/import_c06a6464-07d2-4bb4-8305-c75da3453954"}, {"ref"=>"/subjects/import_7713afda-99d0-4382-b478-29c7c3a1167c"}, {"ref"=>"/subjects/import_0330ec33-8f81-46ed-b221-01bbf11d0cf2"}, {"ref"=>"/subjects/import_87b9ccf4-4873-4aa4-a951-a3eebb894f03"}, {"ref"=>"/subjects/import_eb959373-7080-4a29-9a16-6cf2f30ad375"}, {"ref"=>"/subjects/import_5412219d-8ae6-4cf9-904f-f2ef463377b7"}, {"ref"=>"/subjects/import_2158afa2-e11b-4f15-a145-8d26f01eea6a"}, {"ref"=>"/subjects/import_1e46c0e2-5f32-4c0e-97f9-07ddf8eb9531"}, {"ref"=>"/subjects/import_310a1db4-7b94-4a72-82ca-120f408b82d7"}, {"ref"=>"/subjects/import_80cf34db-8f1e-4d19-8b01-a2f5332471a4"}, {"ref"=>"/subjects/import_a201450a-2a58-45fe-b85f-b499b45b4023"}, {"ref"=>"/subjects/import_1a9edf46-9143-42dd-a46c-ba3894c8d00d"}, {"ref"=>"/subjects/import_ab2fd197-ab6e-4c56-8c66-73832460557d"}], "linked_events"=>[], "extents"=>[{"jsonmodel_type"=>"extent", "import_context"=>"<physdesc class=\"cdata\"> ... </physdesc>", "number"=>"169", "extent_type"=>"Linear Feet", "portion"=>"whole"}], "lang_materials"=>[{"jsonmodel_type"=>"lang_material", "notes"=>[], "import_context"=>"<did class=\"cdata\" id=\"a1\"> ... </did>", "language_and_script"=>{"jsonmodel_type"=>"language_and_script", "language"=>"und"}}], "dates"=>[{"jsonmodel_type"=>"date", "import_context"=>"<unitdate class=\"cdata\" encodinganalog=\"245$f\" type=\"inclusive\"> ... </unitdate>", "date_type"=>"inclusive", "expression"=>"1921-1998.", "label"=>"creation"}], "external_documents"=>[], "rights_statements"=>[], "linked_agents"=>[{"ref"=>"/agents/people/import_b71f978e-703f-4bc5-8c8e-a3f9f4b5d47f", "role"=>"creator", "relator"=>"creator", "terms"=>[]}, {"ref"=>"/agents/families/import_1c6bec99-db8e-43c9-85b0-c2e36da5f606", "role"=>"subject", "relator"=>"subject", "terms"=>[]}, {"ref"=>"/agents/families/import_e71eb985-1fe4-4725-8270-7d170afcc236", "role"=>"subject", "relator"=>"subject", "terms"=>[]}], "import_previous_arks"=>[], "is_slug_auto"=>true, "restrictions"=>false, "revision_statements"=>[], "instances"=>[], "deaccessions"=>[], "related_accessions"=>[], "classifications"=>[], "notes"=>[{"jsonmodel_type"=>"note_singlepart", "content"=>["This collection consists of fifteen series, which include: Biographical Information; Associations, Societies, and Organizations; Awards and Honors; Personal Files; Consulting, Research, and General Correspondence - Domestic; Consulting, Research, and General Correspondence - Foreign; Lectures; Manuscripts; Patent Applications; Patent Information; Polytechnic Files; Reports; Chronological Correspondence; Othmer Images - Photographs, Negatives, and Slides; and Artifacts. The bulk of the paper archives is correspondence pertaining to issues of chemical engineering. His personal life is also represented, particularly in Series I and IV."], "import_context"=>"<abstract class=\"cdata\" encodinganalog=\"520$a\"> ... </abstract>", "type"=>"abstract", "publish"=>true}, {"jsonmodel_type"=>"note_multipart", "subnotes"=>[{"publish"=>true, "jsonmodel_type"=>"note_text", "content"=>"Othmer was born in Omaha, Nebraska on May 11, 1904. In 1927, he earned a Ph. D. in chemical engineering from the University of Michigan. In 1932, he began a career as a professor for the Chemical Engineering Department of Brooklyn Polytechnic Institute, where he remained until his death in 1995. He also consulted for hundreds of companies on numerous chemical engineering issues. He received over 150 patents worldwide. He invented the Othmer Still, a basic laboratory device for the determination of vapor-liquid equilibrium data. He collaborated with Dr. Raymond Kirk to create the Kirk-Othmer Encyclopedia of Chemical Technology."}], "import_context"=>"<bioghist class=\"cdata\" encodinganalog=\"545\" id=\"a2\"> ... </bioghist>", "type"=>"bioghist", "persistent_id"=>"a2", "publish"=>true}, {"jsonmodel_type"=>"note_multipart", "subnotes"=>[{"publish"=>true, "jsonmodel_type"=>"note_text", "content"=>"Collection also includes furniture and unboxed artifacts."}], "import_context"=>"<odd class=\"cdata\" encodinganalog=\"500\" id=\"a5\"> ... </odd>", "type"=>"odd", "persistent_id"=>"a5", "publish"=>true}, {"jsonmodel_type"=>"note_multipart", "subnotes"=>[{"publish"=>true, "jsonmodel_type"=>"note_text", "content"=>"Othmer's patents, lectures, and manuscripts have been bound."}], "import_context"=>"<altformavail class=\"cdata\" encodinganalog=\"530\" id=\"a9\"> ... </altformavail>", "type"=>"altformavail", "persistent_id"=>"a9", "publish"=>true}, {"jsonmodel_type"=>"note_multipart", "subnotes"=>[{"publish"=>true, "jsonmodel_type"=>"note_text", "content"=>"The Donald F. Othmer Papers, Othmer Library of Chemical History, Chemical Heritage Foundation, Philadelphia, Pennsylvania."}], "import_context"=>"<prefercite class=\"cdata\" encodinganalog=\"524\" id=\"a18\"> ... </prefercite>", "type"=>"prefercite", "persistent_id"=>"a18", "publish"=>true}, {"jsonmodel_type"=>"note_multipart", "subnotes"=>[{"publish"=>true, "jsonmodel_type"=>"note_text", "content"=>"Donald F. Othmer; Bequest; 1996."}], "import_context"=>"<acqinfo class=\"cdata\" encodinganalog=\"541\" id=\"a19\"> ... </acqinfo>", "type"=>"acqinfo", "persistent_id"=>"a19", "publish"=>true}, {"jsonmodel_type"=>"note_bibliography", "content"=>["Publications: Thackray, Arnold. and Crow, Amy Beth, eds. Donald Frederick and Mildred Topp Othmer: A Commemorative of Their Lives and Legacies. Philadelphia: Chemical Heritage Foundation, 1999."], "items"=>[], "import_context"=>"<bibliography class=\"cdata\" encodinganalog=\"581\" id=\"a11\"> ... </bibliography>", "persistent_id"=>"a11", "publish"=>true}, {"jsonmodel_type"=>"note_multipart", "subnotes"=>[{"publish"=>true, "jsonmodel_type"=>"note_text", "content"=>"Unpublished finding aid available."}], "import_context"=>"<otherfindaid class=\"cdata\" encodinganalog=\"555\" id=\"a8\"> ... </otherfindaid>", "type"=>"otherfindaid", "persistent_id"=>"a8", "publish"=>true}], "metadata_rights_declarations"=>[], "uri"=>"/repositories/import/resources/import_4f6627d1-465a-4884-8fac-f679bc179286", "publish"=>true, "finding_aid_language"=>"eng", "finding_aid_script"=>"Latn", "finding_aid_title"=>"Finding Aid toThe Donald F. Othmer Papers,<date encodinganalog=\"Date\">1921-1998.</date>", "finding_aid_author"=>"Finding aid prepared by MarcEdit", "finding_aid_language_note"=>"Finding aid written in English.", "level"=>"collection", "title"=>"The Donald F. Othmer Papers,"}>
>   
>   
> In :
>   <ead class="cdata"> ... </ead>
>
> __________________________________
>
> Sarah Newhouse /(she, her, hers)/
> Digital Preservation Archivist
> Othmer Library of Chemical History
> t. +1.215.873.8249
>
> *Science History Institute *
> Chemistry • Engineering • Life Sciences
> 315 Chestnut Street • Philadelphia, PA 19106 • U.S.A.
> Learn about the scientific discoveries that changed our world at 
> sciencehistory.org/learn 
> <https://nam12.safelinks.protection.outlook.com/?url=https%3A%2F%2Fwww.sciencehistory.org%2Flearn&data=05%7C01%7Cmark.custer%40yale.edu%7C9b153ca67a2d4048107f08dab211204d%7Cdd8cbebb21394df8b4114e3e87abeb5c%7C0%7C0%7C638018084010631566%7CUnknown%7CTWFpbGZsb3d8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D%7C3000%7C%7C%7C&sdata=ysbYdMSs5epGIGOk5otuXZWlm5i6lEskiG0KAVvRm0A%3D&reserved=0>
>
>
> _______________________________________________
> Archivesspace_Users_Group mailing list
> Archivesspace_Users_Group at lyralists.lyrasis.org
> http://lyralists.lyrasis.org/mailman/listinfo/archivesspace_users_group
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lyralists.lyrasis.org/pipermail/archivesspace_users_group/attachments/20221020/6497085d/attachment.html>


More information about the Archivesspace_Users_Group mailing list