22

I get the following output (terminal output and blg log file) from running biber build/essay. It fails with error code 2 but doesn't give any error message... how helpful!

[0] Config.pm:311> INFO - This is Biber 2.16
[0] Config.pm:314> INFO - Logfile is 'build/essay.blg'
[120] biber-darwin:340> INFO - === Mon Jan 18, 2021, 04:53:13
[148] Biber.pm:415> INFO - Reading 'build/essay.bcf'
[337] Biber.pm:949> INFO - Using all citekeys in bib section 0
[365] Biber.pm:4340> INFO - Processing section 0
[385] Biber.pm:4531> INFO - Looking for bibtex format file 'essay.bib' for section 0
[388] bibtex.pm:1689> INFO - LaTeX decoding ...
[403] bibtex.pm:1494> INFO - Found BibTeX data source 'essay.bib'

Things used to run fine, but randomly stopped working.

Here's my (sample) essay.bib file.

Update

It seems like the biber run passes when I remmove all numeric fields from the file (e.g., year, volume, number)... odd!

Noldorin
  • 890
  • Biber 2.16, TeX Live 2020, for anyone curious. – Noldorin Jan 18 '21 at 05:27
  • 1
    your bib works fine for me (on windows). Run biber --cache to get the cache location and delete it. Then try again, biber will then unpack itself anew. This sometimes helps. – Ulrike Fischer Jan 18 '21 at 10:00
  • @UlrikeFischer Thank you, that did the trick! I thought deleting build/ would be enough, but evidently not. If you would like to add this as a brief answer, I will immediately upvote and accept. – Noldorin Jan 18 '21 at 16:09
  • See also https://tex.stackexchange.com/q/543837/35864, https://tex.stackexchange.com/q/541486/35864, https://tex.stackexchange.com/q/140814/35864. – moewe Jan 18 '21 at 20:26

2 Answers2

43

Run biber --cache to get the cache location and delete it. Then try again, biber will then unpack itself anew.

Ulrike Fischer
  • 327,261
  • Thank you. Confirming (again) this did the trick. – Noldorin Jan 18 '21 at 16:20
  • 3
    this answer is golden! – songololo Apr 09 '21 at 09:46
  • 1
    I'm not sure if my previous "workaround" for this situation -- restarting my computer -- has the same effect as biber --cache but I'll definitely try this first, next time (it only happens once every few months). – Rico Picone Jul 09 '21 at 22:58
  • To report back, I get this error every few days now, usually after my computer has slept. I use this answer to clear the error and everything works fine. Pretty annoying, though! – Rico Picone Jun 02 '22 at 18:55
  • 1
    @RicoPicone you could try to change the location where the cache is stored. Imho there is an environment variable you could set. – Ulrike Fischer Jun 02 '22 at 19:02
  • Thanks @UlrikeFischer, I'll try that. I should write it in as an option to my aux-clearing script, anyway. – Rico Picone Jun 02 '22 at 21:29
  • Saved me the weekend. Thanks! – Arne Oct 14 '22 at 13:01
  • 1
    I really wonder what's causing the problem. This is an effective solution, but if I had the time to investigate I would definitely try to locate the root cause.. – Trebor Nov 12 '22 at 14:17
  • Great answer, thanks. In addition to this, I also had to delete all the aux files after clearing the biber cache in order to get my project to compile properly. – avivr Jan 19 '23 at 03:52
2

I had the same problem today. Here is another solution.

  1. Changed \usepackage[backend=biber,…]{biblatex} to \usepackage[backend=bibtex,…]{biblatex}
  2. Compiled my file
  3. Changed back to \usepackage[backend=biber]{biblatex}
  4. Compiled again
  5. Problem gone
Franklin
  • 205
  • 2
  • 9