Hello Sean,

At our repo, https://digital.cic.gba.gob.ar/, we have the same issue as 
well. Metadata import fails to parse Authority keys.
I did some debugging and apparently the error is here: 
MetadataImport#isAuthorityControlledField() 
<https://github.com/CICBA/DSpace/blob/a3a52f0d4ad3be55465b02d5cbb507f36ffd403e/dspace-api/src/main/java/org/dspace/app/bulkedit/MetadataImport.java#L1174-L1178>

private static boolean isAuthorityControlledField(String md)
{
      String mdf = StringUtils.substringAfter(md, ":");
      mdf = StringUtils.substringBefore(mdf, "[");
      return authorityControlled.contains(mdf);
}


The problem is in the line 

      String mdf = StringUtils.substringAfter(md, ":");


That method always returns an empty String as there is no character ":"  in 
the metadata names (the CSV headers).

Has anyone an idea of the purpose of this line or the use of the character 
":" in the metadata names?

Many Thanks,
Santi

El viernes, 23 de febrero de 2018, 14:38:27 (UTC-3), Sean Aery escribió:
>
> Hello all,
>
> At Duke, we are working on bringing up DSpace 6.2 and have encountered 
> what appears to be a bug related to how batch metadata import handles 
> authority (key & confidence) data.
>
> Upon metadata export, we correctly see the following in a CSV for 
> dc.contributor.author 
> with authority:
> Jones, Sharon::3333333::600
>
> However, upon a CSV import using the same :: delimiters, the authority key 
> and confidence are seemingly being ignored.
>
>    - adding authority key & confidence to an existing value that 
>    previously had none: no changes detected
>    - changing authority key or confidence on an existing value: no 
>    changes detected
>    - adding a new value with authority key & confidence: the string part 
>    is detected and written but the authority data is discarded
>
> This happens whether using the web UI (xmlui) "Import Metadata" link or 
> the CLI metadata-import command. Has anyone else experienced this? Any 
> ideas for workarounds?
>
> Many thanks,
> Sean
>
> ~~~~~~~~~~~~~~~~~~~~~~
> Sean Aery
> Digital Projects Developer
> Software Development & Integration Services
> Duke University Libraries
> 030U Bostock Library Box 90198
> Durham, NC 27708
> [email protected] <javascript:>
>
> ~~~~~~~~~~~~~~~~~~~~~~
>
>

-- 
All messages to this mailing list should adhere to the DuraSpace Code of 
Conduct: https://duraspace.org/about/policies/code-of-conduct/
--- 
You received this message because you are subscribed to the Google Groups 
"DSpace Technical Support" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To post to this group, send email to [email protected].
Visit this group at https://groups.google.com/group/dspace-tech.
For more options, visit https://groups.google.com/d/optout.

Reply via email to