[NTG-context] XMP metadata schema yields invalid PDF/A

Karl Pettersson karl.pettersson at klpn.se
Sat Feb 5 09:48:16 CET 2022


On Sat, Feb 05, 2022 at 12:37:44AM +0100, luigi scarso via ntg-context wrote:
> On Fri, Feb 4, 2022 at 11:11 PM Karl Pettersson via ntg-context <
> ntg-context at ntg.nl> wrote:
> 
> > On Fri, Feb 04, 2022 at 10:25:27PM +0100, Hans Hagen via ntg-context wrote:
> > > On 2/4/2022 7:29 PM, Karl Pettersson via ntg-context wrote:
> > > > Hi
> > > >
> > > > PDF/A files generated using ConTeXt fail validation with veraPDF, and
> > > > the reason seems to be that the dc:description metadata is defined with
> > > > the wrong type in the embedded XMP extension schema.
> > > >
> > > >
> > https://tex.stackexchange.com/questions/632380/generate-pdf-a-with-context
> > > >
> > > > https://github.com/veraPDF/veraPDF-library/issues/1224
> > > >
> > > > I can reproduce the problem using TeX Live 2021 (MkIV 2021.03.05). The
> > > > definition seems to be controlled by this code.
> > > >
> > > >
> > https://source.contextgarden.net/tex/context/base/mkiv/lpdf-pua.xml?search=rdf#l81
> > > so "dc:description" is not permitted? it is mentioned in
> > >
> > >
> > https://www.dublincore.org/specifications/dublin-core/dcmi-terms/#http://purl.org/dc/elements/1.1/description
> > >
> > > (btw it never failed before)
> >
> > The description element is permitted, but the problem seems to be that
> > its valueType is defined as Text in the embedded schema, while the
> > metadata element in the PDF has an embedded <rdf:Alt><rdf:li
> > xml:lang="x-default"> structure.
> >
> >
> > https://github.com/veraPDF/veraPDF-library/issues/1224#issuecomment-1029932963
> >
> > (I suppose the reference to "title" in the issue comment should be
> > "description".)
> >
> > Validating with veraPDF <1.20 does not raise the error. The validation
> > seems to have changed for redefined types in that version.
> >
> >
> > https://github.com/veraPDF/veraPDF-library/blob/integration/RELEASENOTES.md#validation
> 
> 
> I am missing something here... true
> <dc:description>FOO</dc:description>
> makes a valid pdf 3a with verapdf 1.20.1.
> But dc:description is like dc:title, so where we are redefining
> dc:description as Text ?
> 
> -- 
> luigi

Attach metadata xml for the non-validating and validating example
(extraced with `pdfinfo -meta | xmllint format -`) in the
Github issue.

Here is a reference to the description element. Note that only
description seems to be redefined, not title.

https://source.contextgarden.net/tex/context/base/mkiv/lpdf-pua.xml#l81

> ___________________________________________________________________________________
> If your question is of interest to others as well, please add an entry to the Wiki!
> 
> maillist : ntg-context at ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
> webpage  : http://www.pragma-ade.nl / http://context.aanhet.net
> archive  : https://bitbucket.org/phg/context-mirror/commits/
> wiki     : http://contextgarden.net
> ___________________________________________________________________________________


-- 
Karl Pettersson
Uppsala, Sweden

https://static-dust.klpn.se/
-------------- next part --------------
A non-text attachment was scrubbed...
Name: test.xml
Type: text/xml
Size: 12572 bytes
Desc: not available
URL: <http://mailman.ntg.nl/pipermail/ntg-context/attachments/20220205/2e25e6f9/attachment.xml>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: test-fixed.xml
Type: text/xml
Size: 10782 bytes
Desc: not available
URL: <http://mailman.ntg.nl/pipermail/ntg-context/attachments/20220205/2e25e6f9/attachment-0001.xml>


More information about the ntg-context mailing list