注释字段导致 biblatex 错误

注释字段导致 biblatex 错误

我有一个导致错误的参考书目条目。

@incollection{Ursoiu2013Economic-effici,
    Annote = {% 2015-06-17

The article focuses on the concept of "good administration", reforms around this topic, its relation to legality and efficiency and whether the legal operationalization of good administration on the European level provides an external normative framework for the exercise of discretion of public agencies and other organs.

The first part of the article (section 3) focuses on the tension between legitimacy and efficiency in the development of "administrative systems"

The second part (section 4) discusses the legal operationalizartion of a "principle of good administration" on the European level.

---

Efficiency has been the prevailing paradigm for "structural adjustment reforms" – changes in the structure of administration through NPM. An "ethos of efficiency" promoted by the IMF, World Bank and Council of Europe.

},
    Author = {Naomi Reniutz Ursoiu},
    Booktitle = {Administrative law beyond the state : Nordic perspectives},
    Date-Added = {2015-06-17 12:53:11 +0000},
    Date-Modified = {2015-08-12 09:02:50 +0000},
    Editor = {Anna-Sara Lind and Jane Reichel},
    Publisher = {Martinus Nijhoff Publishers},
    Read = {1},
    Title = {Economic efficiency and legality as criteria for the development of good administration in a globalized order},
    Year = {2013}}

梅威瑟:

\documentclass[11pt,a4paper]{book}
\usepackage[swedish]{babel}
\usepackage[style=authoryear,language=swedish,autocite=footnote,]{biblatex}
\addbibresource{/Users/xjtorm/Dropbox/referenser.bib}
\title{Test} 
\author{Tormod Otter Johansen}

\begin{document}

Lorem ipsum dolor sit amet.\autocite[]{Ursoiu2013Economic-effici}

\printbibliography
\end{document}     

运行此操作会导致以下错误:

Runaway argument?
{\field {booktitle}{Administrative law beyond the state : Nordic pers\ETC.
./manuskript-avhandling.tex:83: File ended while scanning use of \field.

如果该annote字段不在 bibtex 条目中,这个问题就会自行解决。但这是解决问题的唯一方法吗?我是否错误地使用了注释字段?

答案1

问题在于%该字段中的注释,即annote

biber接受字段的参数并生成一个,.bbl其中参数中的行连接成一行。因此,我们得到了类似的东西

...
\field{annotation}{% ...} 
\field{title}{title}

这意味着 LaTeX 看不到}注释值的右括号。

当后端是时,情况会有所不同bibtex。在这种情况下,生成.bbl文件包含

...
\field{annotation}{% 
  %...
  ...%
} 
\field{title}{title}

bibtex连接 bibtex 字段中的行,但然后以固定宽度将它们拆分。

%行后面的是\field{annotation}{%bibtex 字段的注释。所以这种情况下不会出错,但输出不正确。

因此正如@moewe 所说,在 bibtex 字段中添加注释是可以的,只要这些字段被书目处理器忽略并且不会被排版。

在某些字段中包含%解决方案是使用sourcemap,以使值无效,即

\DeclareSourcemap{ \maps{ \map{ \step[fieldset=annote,null] } } }

在将 bibtex 记录写入文件之前,源映射会对其进行操作.bbl

相关内容