Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

ORDERLABEL and LABEL are now MODS metadata instead of METS attributes #5110

Closed
andre-hohmann opened this issue Apr 28, 2022 · 7 comments
Closed
Assignees
Labels

Comments

@andre-hohmann
Copy link
Collaborator

Problem

Until around the end of the last year, the METS attributes ORDERLABEL and LABEL have been written directly in the attributes in the first <mets:div> of the METS-section <mets:structMap TYPE="LOGICAL">, when the keys were specified in the ruleset by the attribute domain="mets:div".

Now, the keys are written as MODS metadata in the <mets:dmdSec> (see examples below). Because of this behaviour, my solution for #4852 does not work anymore.

Solution / Question

The METS attributes ORDERLABEL and LABEL should be written in the internal metadata file in the first <mets:div> of the METS-section <mets:structMap TYPE="LOGICAL"> and not in <mets:dmdSec>.

Is there a reason for the change? Do i have a mistake in the configuration? See the next section.

Configuration

<key id="LABEL" domain="mets:div" >
    <label>main title ‹METS›</label>
    <label lang="de">Haupttitel ‹METS›</label>
</key>
<key id="ORDERLABEL" domain="mets:div">
    <label>main title (sorting) ‹METS›</label>
    <label lang="de">Haupttitel (Sortierung) ‹METS›</label>
</key>

Example

ORDERLABEL and LABEL in METS

<metsHdr CREATEDATE="2020-03-25T14:31:53.274+01:00" LASTMODDATE="2020-04-07T09:24:31.595+02:00">

<structMap TYPE="LOGICAL">
    <div ID="uuid-3d727cdf-c6ac-43ab-abe6-429f4261fbfa" DMDID="uuid-984a1a8d-2f90-3ef2-874f-6553ec8abbcb" ADMID="uuid-849e8aea-9c46-342e-b346-a870bda910bd" TYPE="Manuscript" ORDER="1" ORDERLABEL="Ballerina amante - Mus.3556-F-504a" LABEL="La Ballerina amante - Mus.3556-F-504a">
        <div ID="uuid-b8a3431e-aad9-47d0-94f4-4200fefdaa93" TYPE="TitlePage" ORDER="1"/>
        <div ID="uuid-c6d24a22-98bc-425e-8337-a78d994309ab" DMDID="uuid-51c5d2a5-4d1c-300d-9357-3a717610fdd8" TYPE="Chapter" ORDER="2"/>
    </div>
</structMap>

ORDERLABEL and LABEL in MODS

<mets:metsHdr CREATEDATE="2021-06-21T13:13:00.000+02:00" LASTMODDATE="2022-04-27T12:57:44.632+02:00">

<mets:dmdSec ID="uuid-017a6d80-fde9-3445-a239-bc86ba0c9f14">
    <mets:mdWrap>
        <mets:xmlData>
            <kitodo:kitodo>
                <kitodo:metadata name="CatalogIDSource">046613919</kitodo:metadata>
                <kitodo:metadata name="PlaceOfPublication">Leipzig</kitodo:metadata>
                <kitodo:metadata name="TitleDocMainShort">Literarisches Notizenblatt</kitodo:metadata>
                <kitodo:metadata name="singleDigCollection">Zeitungen</kitodo:metadata>
                <kitodo:metadata name="DocLanguage">ger</kitodo:metadata>
                <kitodo:metadata name="LABEL">Literarisches Notizenblatt</kitodo:metadata>
                <kitodo:metadata name="CatalogIDDigital">425465705</kitodo:metadata>
                <kitodo:metadata name="PlaceOfPublication">Dresden</kitodo:metadata>
                <kitodo:metadata name="PublisherName">Arnold</kitodo:metadata>
                <kitodo:metadata name="ORDERLABEL">Literarisches Notizenblatt</kitodo:metadata>
                <kitodo:metadata name="TSL_ATS">LiteNo</kitodo:metadata>
                <kitodo:metadata name="docType">Newspaper</kitodo:metadata>
                <kitodo:metadata name="CatalogIDPeriodicalDB">2809374-4</kitodo:metadata>
                <kitodo:metadata name="TitleDocMain">Literarisches Notizenblatt</kitodo:metadata>
                <kitodo:metadata name="singleDigCollection">Projekt: Historische Zeitungen</kitodo:metadata>
            </kitodo:kitodo>
        </mets:xmlData>
    </mets:mdWrap>
</mets:dmdSec>

<mets:structMap TYPE="PHYSICAL">
    <mets:div ID="uuid-ab8e006d-f0f5-4f83-83b4-e8751a058374"/>
</mets:structMap>
@matthias-ronge
Copy link
Collaborator

Can you check that domain="mets:div" is in the <key> definition in your ruleset?

@andre-hohmann
Copy link
Collaborator Author

@matthias-ronge : Do you mean the <key> of the attributes?

<key id="LABEL" domain="mets:div">
    <label>main title ‹METS›</label>
    <label lang="de">Haupttitel ‹METS›</label>
</key>
<key id="ORDERLABEL" domain="mets:div">
    <label>main title (sorting) ‹METS›</label>
    <label lang="de">Haupttitel (Sortierung) ‹METS›</label>
</key>

Or do we have to define it somewhere else?

@matthias-ronge
Copy link
Collaborator

No, that’s correct. So this is a bug.

@andre-hohmann
Copy link
Collaborator Author

Could you imagine the reason for the bug?

@matthias-ronge
Copy link
Collaborator

I'm sure my imagination skills are good 😉 but with software it's more a question of research. 💻

Just to be clear, is this in the internal METS file, or only after the export, or both?

@andre-hohmann
Copy link
Collaborator Author

The examples are both internal METS files.

In the exported METS file it is different because of the export XSL:

  1. <kitodo:metadata name="LABEL"> and <kitodo:metadata name="ORDERLABEL"> are not in <mets:dmdSec> of the exported file, because the export of the elements are not configured for the <mets:dmdSec>.
  2. <kitodo:metadata name="LABEL"> and <kitodo:metadata name="ORDERLABEL"> are configured for the <mets:structMap TYPE="LOGICAL">. Thus,the values are in <mets:div LABEL> and in <mets:div ORDERLABEL>
    But only for the current level, not for the first <mets:div> of the superordinate processes as for example newspaper, periodical, ...

Example of the exported file of an newspaper issue

  • uuid-f51ffabc-0558-473c-8585-6621e6196ec9 -> Without LABEL and ORDERLABEL
  • uuid-27c8b504-daea-464f-841e-a80d8659e917 -> With LABEL and ORDERLABEL
    <mets:structMap TYPE="LOGICAL">
        <mets:div ID="uuid-f51ffabc-0558-473c-8585-6621e6196ec9" TYPE="newspaper">
            <mets:mptr LOCTYPE="URL" xlink:href="https://digital.slub-dresden.de/data/kitodo/LiteNo_425465705/LiteNo_425465705.xml"/>
            <mets:div ID="uuid-2956eb68-0d22-4747-bcfe-51204edbcba5" TYPE="year" ORDERLABEL="1850">
                <mets:mptr LOCTYPE="URL" xlink:href="https://digital.slub-dresden.de/data/kitodo/LiteNo_425465705-1850/LiteNo_425465705-1850.xml"/>
                <mets:div TYPE="month" ORDERLABEL="1850-01" ID="uuid-3cceb16c-f493-4731-ab22-11ca4fa52a4f" ADMID="AMD">
                    <mets:div TYPE="day" ID="uuid-bd0acc78-8d37-44e2-8ac9-8d2b5d4c39f7" ORDERLABEL="1850-01-28">
                        <mets:div ID="uuid-27c8b504-daea-464f-841e-a80d8659e917" LABEL="Haupttitel" ORDERLABEL="Haupttitel (Sortierung)" DMDID="uuid-cee50d9a-1c5a-3118-9d62-fff7c597ab8b" TYPE="issue" ORDER="1"/>
                    </mets:div>
                </mets:div>
            </mets:div>
        </mets:div>
    </mets:structMap>

@andre-hohmann
Copy link
Collaborator Author

@matthias-ronge : I am sorry for the confusion! Two aspects led me to the above described conclusion:

  1. The XSL for the migration is wrong. I think that this is the main reason for the behaviour.
  2. I have examined some meta.xml files from the SUB client in the preview system to compare it with our results. They show the same behaviour, which encouraged my idea that it is a general mistake. But it seems that there is a problem with the configuration.

If only one aspect had occurred, i might have search more carefully for the reason. Nevertheless, i can now create processes, with correct ORDER and ORDERLABEL and the export files of newspaper issues are correct.

I close the issue, because the problem does not exist.

Thanks to @henning-gerhardt for the hint with the migrated data.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants