[Tex/LaTex] List of the most common causes and solutions to bugs compiling bibliographies in TeX

biberbiblatexbibliographiescompilingerrors

I start using the Texmaker on my home PC, when I try to run my files I get an error message from this type:

INFO - This is biber 0.9.2

INFO - Logfile is 'bibertest.blg'

FATAL - Cannot find control file 'bibertest.bcf'! - did you pass the "backend=biber" option to BibLaTeX?

Process exited with error(s)

I used this MWE (from a previous post)

%%% Tex File
\documentclass{article}

\usepackage[american]{babel}
\usepackage{csquotes}

\usepackage[backend=biber]{biblatex}

\DeclareLanguageMapping{american}{american-apa}

\addbibresource{NumFactorsTest.bib}

\begin{document}

Some text is here.
\textcite{Akaike1973}
\textcite{Akaike1987}


\printbibliography

\end{document}


%%% BIB file
@InProceedings{Akaike1973,
   author = {H. Akaike},
   title = {Information theory and an extension of the maximum likelihood principle},
   editor = {B. N. Petrov and F. Csaki},
   booktitle = {2nd International Symposium on Information Theory},
   pages = {267-281},
   year = {1973},
   location = {Budapest: Akademiai Kiado} 
}

@article{Akaike1987,
   author = {Akaike},
   title = {Factor analysis and AIC},
   journal = {Psychometrika},
   volume = {52},
   number = {3},
   pages = {317-332},
   year = {1987}
}

.blg file:

[2] Config.pm:324> INFO - This is Biber 2.1
[2] Config.pm:327> INFO - Logfile is 'bibertest.blg'
[232] biber-MSWIN:273> INFO - === %a %b %e, %Y, %H:%M:%S
[597] Utils.pm:162> ERROR - Cannot find control file 'bibertest.bcf'! - did you pass the "backend=biber" option to BibLaTeX?
[598] Biber.pm:110> INFO - ERRORS: 1

.log file (relevant parts):

("C:\Program Files\Miktex 2.9\tex\latex\biblatex\biblatex.sty"
Package: biblatex 2015/04/19 v3.0 programmable bibliographies (PK/JW/AB)
("C:\Program Files\Miktex 2.9\tex\latex\biblatex\biblatex2.sty"
Package: biblatex2 2015/04/19 v3.0 programmable bibliographies (biber) (PK/JW/A
B)


Package biblatex Info: No input encoding detected.
(biblatex) Assuming 'ascii'.
Package biblatex Info: Automatic encoding selection.
(biblatex) Assuming data encoding 'ascii'.
Package biblatex Info: Trying to load bibliographic data...
Package biblatex Info: ... file 'bibertest.bbl' not found.
No file bibertest.bbl.

I check into some potential solutions:


  1. Update MikTeX and configured TexmakerBiblatex + Biber + Texmaker + MiKTeX

I updated MikTeX and configured Texmaker to use biber as follow

enter image description here


  1. Cache folders

I check for cache folders in temporary files

  C:\Users\<username>\AppData\Local\Temp (Windows 7)

but I did not found any cache folder of the type par-<hex_encoded_username>\cache-*.


  1. Mismatch in files – (Bibliography aux file mismatch (.aux.bcf versus .bcf))

I checked for mismatch between files.


  1. Control file (.bcf) –
    Error message when using biber

I also checked other solution to address the issue of not finding the control file, but was not useful.


Are there any additional causes to this bug and which are the alternative solutions I can try? List of most common causes of bugs and solutions could be also a good way to systematize this issue, if this is considered relevant (but I don't know how many more posts I should look to get a solution). Some state-of-art about biber updates and efforts to correct these bugs, if found relevant.

The way I see it there is lot of really good information on tex.stackexchange, but is not gathered, which difficult the task to solve issues with biber and bibliographies in general, which is a important topic for all kind of research.

Note: When I first run the PdfLaTeX before running biber I get a warning message of a busy synctex file. I solve this issue using this answer, but the initial bug remains.

Best Answer

In your case the problem was using the 'Use a "build" subdirectory for output files option' of your editor. When Biber is invoked it looks for the .bcf file (in fact, Biber "compiles" the .bcf). But if the .bcf file has been moved to another subdirectory Biber is unaware of, Biber cannot find the file. For exactly this reason Biber has the --output-directory and --input-directory options, as explained in Finding LaTex output files. Most editors are, however, unaware of this nice feature and do not incorporate this into their 'Use a "build" subdirectory for output files option' feature, so you will have to do that yourself.

The consensus on this site seems to be: Only use such 'Use a "build" subdirectory for output files option' option if you know what you are (and what it is !) doing. If you have a nice folder structure set up for your document, you will be able to cope with the temporary files produced by LaTeX and friends just fine.


In my experience the most frequent issued faced when trying to get biblatex and Biber running are the following. You will note that only one of them can really be considered a bug, albeit one that was introduced by an upstream package.

  1. Failure to run Biber. Especially beginners using editor/IDE environments often don't realise that one has to run an external programme on the files. One does not only need LaTeX to compile the file, but Biber as well. See the often viewed Question mark instead of citation number. For those wishing to have their editor support Biber there is then also Biblatex with Biber: Configuring my editor to avoid undefined citations.

  2. Mismatching biblatex and Biber versions. Of course it is always recommended to keep all components of the system up to date with regular updates. This is even more crucial for biblatex and Biber, since a particular version of biblatex only works together with a specific version of Biber. Refer to the biblatex documentation for the Biber/Biblatex compatibility matrix (table 1 on page 6 in version 3.0 of the doc). The warning one gets when this problem occurs is along the lines of

    Warning: Found biblatex control file version 2.5, expected version 2.4

    Indeed this is only a warning and in some cases the compilation still goes through if you press on, but more often than not this causes trouble and grief further down the road. One has to keep in mind here that the biblatex control file (bcf) version does not necessarily agree with either biblatex's or Biber's version. Currently, biblatex is at version 3.0, Biber at 2.1 and the corresponding bcf version is 2.5.

  3. Biber's infamous cache bug. Sometimes Biber chokes on its cache folder - is has not been properly unpacked or otherwise been corrupted. This is a known problem and makes itself known with strange Biber errors and warnings along the lines of

    Use of uninitialized value $llabel in concatenation (.) or string at Biber.pm line 1741

    and

    data source C:\Users\UserName\AppData\Local\Temp\par-416e6a61\cache-46f2da95c5284272f49f4e60b997c7e3f24afb19\recode_data.xml not found in .

    As explained in Biblatex/biber fails with a strange error about missing recode_data.xml file? this can be remedied by deleting Biber's cache folder. In the linked question, one of Biber's developers announced that the relevant Perl package has been updated and so the bug should be removed in future versions of Biber.

  4. Non-standard, non-uniform or malformed .bib file. Often, this does not lead to errors or warnings, but to awkward output. Sometimes people just download reference information off the internet or let their reference manager export a .bib file without reviewing the resulting .bib file. These files can contain awkward constructs such as note = {\url{www.example.com} accessed 1. September 2014}, when the biblatex way would be url = {www.example.com}, urldate = {2014-09-01}. People sometimes use @misc for works where the @online entry type would be more appropriate. For a list of supported types, their fields and the meaning of those refer to ยง2 Database Guide of the biblatex documentation. A good example for a clean .bib file for biblatex is biblatex-examples.bib.

It might go without saying, but if you have identified a problem and have fixed it it is always a good idea to delete temporary files (.aux, .bcf, ...) to make sure the compilation can got through without any legacy problems in the temporary files.

Related Question