artefactual-labs / mets-reader-writer

Library to parse and create METS files, especially for Archivematica.
https://mets-reader-writer.readthedocs.io
GNU Affero General Public License v3.0
20 stars 13 forks source link

Fix access to elements with clashing tags #68

Closed sevein closed 5 years ago

sevein commented 5 years ago

premisrw couldn't handle access to attributes when the schema used the same attribute name in more than one element, e.g. startDate and endDate are values used multiple times under PREMISRights. This pull request solves the problem by introducing alternative keys qualified with the path to the value instead, e.g. foo__bar__start_date instead of start_date when there is a clash.

Also, added some missing role attributes to the PREMISRights schema.

Connects to https://github.com/archivematica/Issues/issues/446.