# File ended while scanning use of \field

I have the issue that more or less out of nothing my thesis doesn't compile any more, specifically the bibliography (without it it runs through smoothly). I use classicthesis template, which is quite the monster. The issue is however also persistent if I make a minimal example with the standard article class.

\documentclass[]{article}
\usepackage{csquotes}
\PassOptionsToPackage{%
%backend=bibtex,
%bibencoding=ascii,%
language=auto,%,
style=numeric-comp,%
%style=authoryear-comp, % Author 1999, 201
%bibstyle=ieeetr,dashed=false, % dashed: substitute rep. author with ---
%sorting=nyt, % name, year, title
maxbibnames=10, % default: 3, et al.
backref=true,%
natbib=true % natbib compatibility mode (\citep and \citet still work)
}{biblatex}

\usepackage[sorting=none]{biblatex}
%opening
\title{}
\author{}
\begin{document}

\maketitle

\begin{abstract}

\end{abstract}
\cite{Cleland2013}
\section{}

\end{document}


where the bib file has a single entry:

@article{Cleland2013,
abstract = {Past, current and projected future population growth is outlined. Barring a calamitous pandemic, a further increase in the world's population from 7 to between 8.8 and 10 billion by mid-century is unavoidable. This increase is driven by high fertility in sub-Saharan Africa whose population is forecast to more than double in the next 40 years and by a modest rise of 23 % in Asia's huge population. Beyond mid-century, the range of plausible demographic destinations widens; much depends on fertility rates in the next few decades because they will determine the number of potential reproducers in the second half of the century. Vigorous promotion of family planning, particularly in Africa, is crucial to achievement of population stabilisation. Unchanged fertility implies a global population of 25 billion by the end of the century. In the next few decades the contribution of human population growth to global environmental change is moderate, because nearly all growth will occur in poor countries where consumption and emission of greenhouse gases is low. The implications for food production, and thereby water consumption, are greater. Much of the future need for food will be driven by increased numbers rather than changing diets. Loss of bio-diversity and natural habitats, degradation of fragile eco-systems due to over-exploitation and aquifer deletion are likely consequences. {\textcopyright} 2013 Springer Science+Business Media Dordrecht.},
author = {Cleland, John},
doi = {10.1007/s10640-013-9675-6},
issn = {0924-6460},
journal = {Environ. Resour. Econ.},
keywords = {Age structure,Contraception,Demographic transition,Fertility,Population growth,Population projections},
mendeley-groups = {thesis},
month = {aug},
number = {4},
pages = {543--554},
title = {{World Population Growth; Past, Present and Future}},
volume = {55},
year = {2013}
}


I cannot figure out the issue, been trying since yesterday... the error message is a bit ambiguous:

Zeile 23: File ended while scanning use of \field. \begin{document}
Zeile 27: Undefined control sequence. \begin{abstract}
Zeile 30: Missing number, treated as zero. \cite{Cleland2013}
Zeile 30: Missing number, treated as zero. \cite{Cleland2013}
Zeile 30: Missing number, treated as zero. \cite{Cleland2013}

• The abstract field contains an unescaped % sign. Either remove the complete abstract field or escape the % to \%. Mar 23, 2020 at 7:24
• Unrelated to the issue, but note that month = {aug}, is wrong. The three-letter month name abbreviations must be used without braces or quotation marks as they are technically built-in @string values. It should be month = aug,. With biblatex (which you are using) it is preferable not to use the month field at all and to combine year and month into the date field (in ISO 8601 format): date = {2013-04},. Mar 23, 2020 at 7:28
• The error messages you quote seem to be shortened versions of the complete message that can be found in the .log. I assume your editor somehow parses the messages for you. The complete message is a tiny bit more helpful, since it provides a hint where the issue may be located: Runaway argument? {Past, current and projected future population growth is outlined. Ba\ETC. So the message strongly suggests that the problem is related to the abstract field. Mar 23, 2020 at 7:31
• Mar 23, 2020 at 7:35

The full error message one gets in the .log file when trying to cite the entry from the question is a tiny bit more helpful than the digest from your editor

(abstract-prob.bbl)
Runaway argument?
{Past, current and projected future population growth is outlined. Ba\ETC.
! File ended while scanning use of \field.
<inserted text>
\par
l.33 \begin{document}


The line above the error message gives you a hint where exactly you need to look for the culprit. The quoted text "Past, current and projected future population growth is outlined." is the beginning of the abstract field in your entry.

A closer look at that field (line breaks added for legibility)

abstract = {Past, current and projected future population growth is outlined.
Barring a calamitous pandemic, a further increase in the world's population
from 7 to between 8.8 and 10 billion by mid-century is unavoidable.
This increase is driven by high fertility in sub-Saharan Africa
whose population is forecast to more than double in the next 40 years
and by a modest rise of 23 % in Asia's huge population.
Beyond mid-century, the range of plausible demographic destinations widens;
much depends on fertility rates in the next few decades because
they will determine the number of potential reproducers in
the second half of the century.
Vigorous promotion of family planning, particularly in Africa,
is crucial to achievement of population stabilisation.
Unchanged fertility implies a global population of 25 billion
by the end of the century.
In the next few decades the contribution of human population
growth to global environmental change is moderate,
because nearly all growth will occur in poor countries
where consumption and emission of greenhouse gases is low.
The implications for food production,
and thereby water consumption, are greater.
Much of the future need for food will be driven by increased
numbers rather than changing diets.
Loss of bio-diversity and natural habitats,
degradation of fragile eco-systems due to over-exploitation
and aquifer deletion are likely consequences.


shows that it contains an unescaped % sign.

This field ends up in the .bbl file as follows (without line breaks)

  \field{abstract}{Past, current and projected future population growth is outlined. Barring a calamitous pandemic, a further increase in the world's population from 7 to between 8.8 and 10 billion by mid-century is unavoidable. This increase is driven by high fertility in sub-Saharan Africa whose population is forecast to more than double in the next 40 years and by a modest rise of 23 % in Asia's huge population. Beyond mid-century, the range of plausible demographic destinations widens; much depends on fertility rates in the next few decades because they will determine the number of potential reproducers in the second half of the century. Vigorous promotion of family planning, particularly in Africa, is crucial to achievement of population stabilisation. Unchanged fertility implies a global population of 25 billion by the end of the century. In the next few decades the contribution of human population growth to global environmental change is moderate, because nearly all growth will occur in poor countries where consumption and emission of greenhouse gases is low. The implications for food production, and thereby water consumption, are greater. Much of the future need for food will be driven by increased numbers rather than changing diets. Loss of bio-diversity and natural habitats, degradation of fragile eco-systems due to over-exploitation and aquifer deletion are likely consequences. © 2013 Springer Science+Business Media Dordrecht.}


When LaTeX encounters that % sign while reading the contents of the abstract field from the .bbl file, we get an error because the % sign turns the rest of the line into a comment, which means that the closing curly brace } at the end of the field is not seen.

That causes the

! File ended while scanning use of \field.


error.

The solution is to escape the % sign in the abstract field to \%.

Since most bibliography styles ignore the abstract field anyway it might be a better idea to just remove the field from the .bib file completely. (This can be done on the fly by Biber, see Error with percent sign in bib entry field when using biblatex/biber, but it is much better to delete the field from the .bib file completely and directly.) If you need the abstract it is theoretically possible to escape the %s on the fly Prevent biber from choking on "%" characters in abstract?.