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

Extra comma when citing source without author in footnote with author-in-text style #7800

Closed
cgm616 opened this issue Jan 3, 2022 · 4 comments
Labels

Comments

@cgm616
Copy link

cgm616 commented Jan 3, 2022

Explain the problem.
When citing a source without an author in Chicago style using author-in-text mode inside a footnote, pandoc inserts an extra comma and space before the citation. This sort of citation is extremely useful since Chicago style does not call for parentheses when using citations in discursive footnotes.

test.md:

---
csl: http://www.zotero.org/styles/chicago-fullnote-bibliography
references:
- id: CurtissStrong1809
  citation-key: CurtissStrong1809
  container-title: Day
  issued:
    - year: 1809
      month: 6
      day: 1
  page: '51'
  title: Curtiss v. Strong
  type: legal_case
  volume: '4'
reference-section-title: "Bibliography"
---

# Body

This is what a normal citation should look like.[@CurtissStrong1809]
Now, we'll cite it inside a footnote.^[For instance, see @CurtissStrong1809 [p. 52].]

Output of pandoc --citeproc test.md -o test.pdf:

[snip]
Footnote 1: Curtiss v. Strong, 4 Day 51 (1809).
Footnote 2: For instance, see , Curtiss v. Strong, 4 Day at 52.

Expected output:

[snip]
Footnote 1: Curtiss v. Strong, 4 Day 51 (1809).
Footnote 2: For instance, see Curtiss v. Strong, 4 Day at 52.

This seems to be because of the way that pandoc uses citeproc to simulate author-in-text citations, but I don't know Haskell and couldn't really figure it out. It is not limited to legal cases.

Pandoc version?
I am using pandoc version 2.16.2 on macOS Monterey 12.1.

> pandoc --version
pandoc 2.16.2
Compiled with pandoc-types 1.22.1, texmath 0.12.3.2, skylighting 0.12.1,
citeproc 0.6, ipynb 0.1.0.2
User data directory: /Users/cgm616/.local/share/pandoc
Copyright (C) 2006-2021 John MacFarlane. Web:  https://pandoc.org
This is free software; see the source for copying conditions. There is no
warranty, not even for merchantability or fitness for a particular purpose.
@cgm616 cgm616 added the bug label Jan 3, 2022
@jgm
Copy link
Owner

jgm commented Jan 3, 2022

Since this is a footnote style, you can just do

Now, we'll cite it inside a footnote [For instance, see @CurtissStrong1809, p. 52].

and pandoc will put it in a note for you. That's the recommended way of writing citations (it makes it possible to switch easily to a non-footnote style).

@jgm
Copy link
Owner

jgm commented Jan 3, 2022

This issue looks like a dup of #7761 which is already fixed in master!
You can try a nightly.

@jgm jgm closed this as completed Jan 3, 2022
@cgm616
Copy link
Author

cgm616 commented Jan 3, 2022

I'll try a nightly. The reason I'm not using the preferred method is because I can't seem to get it to work with multiple references in the same footnote.

Now, we'll cite it inside a footnote.[For instance, see @CurtissStrong1809, p. 52 and @austinHowThingsWords1965.]

The above only renders How to Do Things with Words, The William James Lectures: 1955 (Oxford University Press, 1965). in the footnote and sometimes results in strange artifacts showing up in the text.

@jgm
Copy link
Owner

jgm commented Jan 4, 2022

If you replace "and" with a semicolon, it will work (though you won't get the word "and").

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