ArchivesSpace EAD outputs have invalid "ns2" namespace references (imported from Archivists' Toolkit-era finding aids)


Hi ASpace team,

We're writing to re-open an EAD validation issue that our colleagues at UCI Library Special Collections & Archives have noticed. It appears to be a long-standing bug, related to this older JIRA ticket:

In a nutshell, Archivists' Toolit-era EADs that were imported into ASpace have vestigal "ns2" namespace references, pre-pended to various EAD tag attributes. When those EADs were imported into ASpace, those vestigal "ns2"'s were carried over into ASpace – and they come through the EADs exported from ASpace. This is producing validation errors, as the root <ead> tag doesn't declare the "ns2" namespace.

Example references, provided below.

Can the ASpace EAD output be updated to include that namespace – or alternatively, provide a solution to bulk delete those "ns2" references within Resource records (without having to programmatically work directly with the raw data, in the backend database)?

Many institutions such as UCI Library imported or migrated legacy Archivists' Toolkit-era finding aids into ASpace, years ago – so it's not really an option to go back and clean up the data prior to import.


– Adrian


Adrian Turner
Senior Product Manager
California Digital Library
(510) 287-3390


[#1] Version of EAD, as exported from Archivists' Toolkit

[#2] Successfully imported result of #1 in ASpace 2.6.0 sandbox

[#3] Version of EAD, as exported from ASpace 2.6.0 sandbox (see attached)




Adrian Turner
July 10, 2019, 9:28 PM

Also attaching #1 (Version of EAD, as exported from Archivists' Toolkit). Please use this version, for debugging purposes (the instance at may eventually be updated).


– Adrian



Adrian Turner
July 10, 2019, 10:31 PM

Reattaching #3 here.


Lora Woodford
December 12, 2019, 8:01 PM

My vote would be to pursue doing this as a one-time background job to cleanup this imported/improper data similar to the “Strip whitespace” plugin that implemented a while back. This will get rid of them once and for all without having to do any additional/hidden magic as part of the EAD export.

Adrian Turner
January 8, 2020, 7:17 PM

If a plug-in were available to do a one-time cleanup of the vestigial "ns2" namespace data, we could definitely utilize that (for the use case we reported).

Adrian Turner
February 19, 2020, 7:50 PM

… or, can ASpace update the default EAD output to declare ns2 as an additional namespace? That would be the easiest fix.




Adrian Turner

Affects versions