[citeproc-bug] Format error with disambiguated in-line cites
Hi,
I set-up my in-line citations to disambiguate by year, such that they are displayed as follows:
(Khan et al. 1980; Lance et al. 1985; Thorbjarnarson 1993a,b; Hekkala et al. 2011)
Unfortunately, the cite immediately before the disambiguated citation seems to not want to follow the command and this is what I get:
(Khan et al. 1980; Lance et al. 1985,Thorbjarnarson 1993a,b; Hekkala et al. 2011)
Here is the relevant code:
<macro name="year-date">
<choose>
<if variable="issued">
<date variable="issued">
<date-part name="year"/>
</date>
<text variable="year-suffix" font-style="normal"/>
</if>
<else>
<text term="no date" form="short"/>
</else>
</choose>
</macro>
<citation et-al-min="3" et-al-use-first="1" disambiguate-add-year-suffix="true" collapse="year-suffix" year-suffix-delimiter="," disambiguate-add-givenname="true" givenname-disambiguation-rule="by-cite">
<sort>
<key macro="year-date"/>
<key macro="author-short"/>
</sort>
<layout delimiter="; " prefix="(" suffix=")">
<group delimiter=":">
<group delimiter=" ">
<text macro="author-short"/>
<text macro="year-date"/>
</group>
<text variable="locator"/>
</group>
</layout>
</citation>
Thoughts??
I set-up my in-line citations to disambiguate by year, such that they are displayed as follows:
(Khan et al. 1980; Lance et al. 1985; Thorbjarnarson 1993a,b; Hekkala et al. 2011)
Unfortunately, the cite immediately before the disambiguated citation seems to not want to follow the command and this is what I get:
(Khan et al. 1980; Lance et al. 1985,Thorbjarnarson 1993a,b; Hekkala et al. 2011)
Here is the relevant code:
<macro name="year-date">
<choose>
<if variable="issued">
<date variable="issued">
<date-part name="year"/>
</date>
<text variable="year-suffix" font-style="normal"/>
</if>
<else>
<text term="no date" form="short"/>
</else>
</choose>
</macro>
<citation et-al-min="3" et-al-use-first="1" disambiguate-add-year-suffix="true" collapse="year-suffix" year-suffix-delimiter="," disambiguate-add-givenname="true" givenname-disambiguation-rule="by-cite">
<sort>
<key macro="year-date"/>
<key macro="author-short"/>
</sort>
<layout delimiter="; " prefix="(" suffix=")">
<group delimiter=":">
<group delimiter=" ">
<text macro="author-short"/>
<text macro="year-date"/>
</group>
<text variable="locator"/>
</group>
</layout>
</citation>
Thoughts??
What I want: (Khan et al. 1980; Lance et al. 1985; Thorbjarnarson 1993a,b; Hekkala et al. 2011)
What I get: (Khan et al. 1980; Lance et al. 1985,Thorbjarnarson 1993a,b; Hekkala et al. 2011)
The difference is in the Lance et al. 1985 citation, which in the former is followed by a "; " and in the latter is followed by a ","
@Frank: validating copy of the style is here:
https://gist.github.com/adam3smith/426e0ea28e4fa773d20b
Problem is that the style always turns the delimiter before a cite collapsed by year suffix into a comma. See the above example, but I was able to replicate that with random data. Let me know if you need anything else.
(@tersiphone -- you always want to validate when something isn't working to make sure the problem isn't your code)
https://gist.github.com/anonymous/4128451671229336d71f