In the case of a structure that is being deprecated via @validUntil, it will (or at least should) have both a <desc xml:lang="en"> to describe the thing being described, and a <desc type="deprecationInfo" xml:lang="en">. Thus the XPath on the L side of the 1st gt in the <xsl:sequence> resolves to a sequence of 2 element nodes, and the function dies as gt does not handle sequences.
The fix is to add something like a [not( @type eq 'deprecationInfo') ] predicate to the both the XPaths that seek <desc> elements (on both L and R side of the gt.)
I could have sworn we fixed this already, but cannot find an issue or PR about it (whether open or closed).
In common/functions.xsl tei:descOrGlossOutOfDate() is defined as
In the case of a structure that is being deprecated via
@validUntil
, it will (or at least should) have both a<desc xml:lang="en">
to describe the thing being described, and a<desc type="deprecationInfo" xml:lang="en">
. Thus the XPath on the L side of the 1stgt
in the<xsl:sequence>
resolves to a sequence of 2 element nodes, and the function dies asgt
does not handle sequences.The fix is to add something like a
[not( @type eq 'deprecationInfo') ]
predicate to the both the XPaths that seek<desc>
elements (on both L and R side of thegt
.)