I recently had to reformat my D: drive where MiKTeX was installed. I reinstalled MiKTeX, but now the project I was working on won't compile. I tried repairing, uninstalling, and reinstalling MiKTeX, but nothing worked. Finally, I uninstalled MiKTeX and installed TeXLive, but the issue persists.

When I try to run pdflatex, I get the error:

(d:/Program Files/texlive/2020/texmf-dist/tex/latex/biblatex/biblatex.sty
(d:/Program Files/texlive/2020/texmf-dist/tex/latex/logreq/logreq.sty
(d:/Program Files/texlive/2020/texmf-dist/tex/latex/logreq/logreq.def))
! Text line contains an invalid character.
l.2175      \bgroup\nohyphenation#1\egroup^^^

Texmaker shows that the issue is in the biblatex.sty file. Lines 2171-2175 from that file:


I haven't edited this file.

If I type in R when pdflatex is paused, the compilation continues and the pdf is created without errors from what I can tell, so this is really just a convenience issue. I can't e.g. compile the project in Texmaker.


This is pdfTeX, Version 3.14159265-2.6-1.40.21 (TeX Live 2020/W32TeX) (preloaded format=pdflatex 2020.10.1)  1 OCT 2020 21:59
entering extended mode
 restricted \write18 enabled.
 %&-line parsing enabled.
LaTeX2e <2020-02-02> patch level 5
L3 programming layer <2020-09-24> (./tauthesis.cls
Document Class: tauthesis 2020/05/18 v1.6 Thesis styles used in Tampere Univers
(d:/Program Files/texlive/2020/texmf-dist/tex/latex/base/report.cls
Document Class: report 2019/12/20 v1.4l Standard LaTeX document class
(d:/Program Files/texlive/2020/texmf-dist/tex/latex/base/size12.clo
File: size12.clo 2019/12/20 v1.4l Standard LaTeX file (size option)
(d:/Program Files/texlive/2020/texmf-dist/tex/latex/pdfx/pdfx.sty
Package: pdfx 2019/02/27 v1.6.3 PDF/X and PDF/A support (CVR/HTH/RRM/PS)

(d:/Program Files/texlive/2020/texmf-dist/tex/generic/iftex/iftex.sty
Package: iftex 2020/03/06 v1.0d TeX engine tests
(d:/Program Files/texlive/2020/texmf-dist/tex/generic/iftex/ifpdf.sty
Package: ifpdf 2019/10/25 v3.4 ifpdf legacy package. Use iftex instead.
(d:/Program Files/texlive/2020/texmf-dist/tex/generic/iftex/ifxetex.sty
Package: ifxetex 2019/10/25 v0.7 ifxetex legacy package. Use iftex instead.
(d:/Program Files/texlive/2020/texmf-dist/tex/latex/ms/everyshi.sty
Package: everyshi 2001/05/15 v3.00 EveryShipout Package (MS)
(d:/Program Files/texlive/2020/texmf-dist/tex/generic/iftex/ifluatex.sty
Package: ifluatex 2019/10/25 v1.5 ifluatex legacy package. Use iftex instead.
){d:/Program Files/texlive/2020/texmf-var/fonts/map/pdftex/updmap/pdftex.map}
(d:/Program Files/texlive/2020/texmf-dist/tex/latex/base/inputenc.sty
Package: inputenc 2018/08/11 v1.3c Input encoding file
(d:/Program Files/texlive/2020/texmf-dist/tex/latex/pdfx/l8u-penc.def
File: l8u-penc.def 2017/06/23 v0.8 Custom LaTeX file, for UTF8 encoded letters 
and symbols
LaTeX Info: Composite with undeclared \b in encoding L8U on input line 278.

(d:/Program Files/texlive/2020/texmf-dist/tex/latex/pdfx/l8ugrk-penc.def
File: l8ugrk-penc.def 2018/11/28 v0.6 Greek support for UTF8 in XMP metadata
(d:/Program Files/texlive/2020/texmf-dist/tex/latex/pdfx/l8umath-penc.def
File: l8umath-penc.def 2017/06/23 v0.6 Custom LaTeX file, for UTF8 encoded math

(d:/Program Files/texlive/2020/texmf-dist/tex/latex/xcolor/xcolor.sty
Package: xcolor 2016/05/11 v2.12 LaTeX color extensions (UK)

(d:/Program Files/texlive/2020/texmf-dist/tex/latex/graphics-cfg/color.cfg
File: color.cfg 2016/01/02 v1.6 sample color configuration
Package xcolor Info: Driver file: pdftex.def on input line 225.

(d:/Program Files/texlive/2020/texmf-dist/tex/latex/graphics-def/pdftex.def
File: pdftex.def 2020/08/26 v1.2 Graphics/color driver for pdftex
Package xcolor Info: Model `cmy' substituted by `cmy0' on input line 1348.
Package xcolor Info: Model `hsb' substituted by `rgb' on input line 1352.
Package xcolor Info: Model `RGB' extended on input line 1364.
Package xcolor Info: Model `HTML' substituted by `rgb' on input line 1366.
Package xcolor Info: Model `Hsb' substituted by `hsb' on input line 1367.
Package xcolor Info: Model `tHsb' substituted by `hsb' on input line 1368.
Package xcolor Info: Model `HSB' substituted by `hsb' on input line 1369.
Package xcolor Info: Model `Gray' substituted by `gray' on input line 1370.
Package xcolor Info: Model `wave' substituted by `hsb' on input line 1371.

(d:/Program Files/texlive/2020/texmf-dist/tex/latex/hyperref/hyperref.sty
Package: hyperref 2020-05-15 v7.00e Hypertext links for LaTeX

(d:/Program Files/texlive/2020/texmf-dist/tex/generic/ltxcmds/ltxcmds.sty
Package: ltxcmds 2020-05-10 v1.25 LaTeX kernel commands for general use (HO)
(d:/Program Files/texlive/2020/texmf-dist/tex/generic/pdftexcmds/pdftexcmds.sty
Package: pdftexcmds 2020-06-27 v0.33 Utility functions of pdfTeX for LuaTeX (HO
(d:/Program Files/texlive/2020/texmf-dist/tex/generic/infwarerr/infwarerr.sty
Package: infwarerr 2019/12/03 v1.5 Providing info/warning/error messages (HO)
Package pdftexcmds Info: \pdf@primitive is available.
Package pdftexcmds Info: \pdf@ifprimitive is available.
Package pdftexcmds Info: \pdfdraftmode found.
) (d:/Program Files/texlive/2020/texmf-dist/tex/latex/graphics/keyval.sty
Package: keyval 2014/10/28 v1.15 key=value parser (DPC)
(d:/Program Files/texlive/2020/texmf-dist/tex/generic/kvsetkeys/kvsetkeys.sty
Package: kvsetkeys 2019/12/15 v1.18 Key value parser (HO)
(d:/Program Files/texlive/2020/texmf-dist/tex/generic/kvdefinekeys/kvdefinekeys
Package: kvdefinekeys 2019-12-19 v1.6 Define keys (HO)
(d:/Program Files/texlive/2020/texmf-dist/tex/generic/pdfescape/pdfescape.sty
Package: pdfescape 2019/12/09 v1.15 Implements pdfTeX's escape features (HO)
(d:/Program Files/texlive/2020/texmf-dist/tex/latex/hycolor/hycolor.sty
Package: hycolor 2020-01-27 v1.10 Color options for hyperref/bookmark (HO)
(d:/Program Files/texlive/2020/texmf-dist/tex/latex/letltxmacro/letltxmacro.sty
Package: letltxmacro 2019/12/03 v1.6 Let assignment for LaTeX macros (HO)
) (d:/Program Files/texlive/2020/texmf-dist/tex/latex/auxhook/auxhook.sty
Package: auxhook 2019-12-17 v1.6 Hooks for auxiliary files (HO)
(d:/Program Files/texlive/2020/texmf-dist/tex/latex/kvoptions/kvoptions.sty
Package: kvoptions 2019/11/29 v3.13 Key value format for package options (HO)

(d:/Program Files/texlive/2020/texmf-dist/tex/latex/hyperref/pd1enc.def
File: pd1enc.def 2020-05-15 v7.00e Hyperref: PDFDocEncoding definition (HO)
(d:/Program Files/texlive/2020/texmf-dist/tex/generic/intcalc/intcalc.sty
Package: intcalc 2019/12/15 v1.3 Expandable calculations with integers (HO)
(d:/Program Files/texlive/2020/texmf-dist/tex/generic/etexcmds/etexcmds.sty
Package: etexcmds 2019/12/15 v1.7 Avoid name clashes with e-TeX commands (HO)
Package hyperref Info: Option `pdfa' set `true' on input line 4338.
Package hyperref Info: Hyper figures OFF on input line 4464.
Package hyperref Info: Link nesting OFF on input line 4469.
Package hyperref Info: Hyper index ON on input line 4472.
Package hyperref Info: Plain pages OFF on input line 4479.
Package hyperref Info: Backreferencing OFF on input line 4484.
Package hyperref Info: Implicit mode ON; LaTeX internals redefined.
Package hyperref Info: Bookmarks ON on input line 4717.

(d:/Program Files/texlive/2020/texmf-dist/tex/latex/url/url.sty
Package: url 2013/09/16  ver 3.4  Verb mode for urls, etc.
LaTeX Info: Redefining \url on input line 5076.

(d:/Program Files/texlive/2020/texmf-dist/tex/generic/bitset/bitset.sty
Package: bitset 2019/12/09 v1.3 Handle bit-vector datatype (HO)

(d:/Program Files/texlive/2020/texmf-dist/tex/generic/bigintcalc/bigintcalc.sty
Package: bigintcalc 2019/12/15 v1.5 Expandable calculations on big integers (HO
Package hyperref Info: Hyper figures OFF on input line 6347.
Package hyperref Info: Link nesting OFF on input line 6352.
Package hyperref Info: Hyper index ON on input line 6355.
Package hyperref Info: backreferencing OFF on input line 6362.
Package hyperref Info: Link coloring OFF on input line 6367.
Package hyperref Info: Link coloring with OCG OFF on input line 6372.
Package hyperref Info: PDF/A mode ON on input line 6375.
LaTeX Info: Redefining \ref on input line 6417.
LaTeX Info: Redefining \pageref on input line 6421.
 (d:/Program Files/texlive/2020/texmf-dist/tex/generic/atbegshi/atbegshi.sty
Package: atbegshi 2019/12/05 v1.19 At begin shipout hook (HO)
Package hyperref Info: Driver: hpdftex.
 (d:/Program Files/texlive/2020/texmf-dist/tex/latex/hyperref/hpdftex.def
File: hpdftex.def 2020-05-15 v7.00e Hyperref driver for pdfTeX

(d:/Program Files/texlive/2020/texmf-dist/tex/latex/atveryend/atveryend.sty
Package: atveryend 2019-12-11 v1.11 Hooks at the very end of document (HO)
Package atveryend Info: \enddocument detected (standard20110627).

(d:/Program Files/texlive/2020/texmf-dist/tex/latex/rerunfilecheck/rerunfileche
Package: rerunfilecheck 2019/12/05 v1.9 Rerun checks for auxiliary files (HO)

(d:/Program Files/texlive/2020/texmf-dist/tex/generic/uniquecounter/uniquecount
Package: uniquecounter 2019/12/15 v1.4 Provide unlimited unique counter (HO)
Package uniquecounter Info: New unique counter `rerunfilecheck' on input line 2
Package hyperref Info: Option `unicode' set `true' on input line 1463.

(d:/Program Files/texlive/2020/texmf-dist/tex/latex/hyperref/puenc.def
File: puenc.def 2020-05-15 v7.00e Hyperref: PDF Unicode definition (HO)
(d:/Program Files/texlive/2020/texmf-dist/tex/generic/stringenc/stringenc.sty
Package: stringenc 2019/11/29 v1.12 Convert strings between diff. encodings (HO
Package hyperref Info: Option `psdextra' set `true' on input line 1465.

(d:/Program Files/texlive/2020/texmf-dist/tex/latex/hyperref/psdextra.def
File: psdextra.def 2020-05-15 v7.00e Hyperref: Additions to PDF string support
(d:/Program Files/texlive/2020/texmf-dist/tex/generic/colorprofiles/colorprofil
Package: colorprofiles 2018/11/01 v1.0.1 color profiles for PDF/X and PDF/A sup

(d:/Program Files/texlive/2020/texmf-dist/tex/generic/colorprofiles/colorprofil
(d:/Program Files/texlive/2020/texmf-dist/tex/generic/stringenc/se-pdfdoc.def
File: se-pdfdoc.def 2019/11/29 v1.12 stringenc: PDFDocEncoding
(d:/Program Files/texlive/2020/texmf-dist/tex/latex/pdfx/AdobeColorProfiles.tex
) (d:/Program Files/texlive/2020/texmf-dist/tex/latex/pdfx/8bit.def
File: 8bit.def 2008/03/30 v1.1d Input encoding file
** pdfx: No file main.xmpdata . Metadata will be incomplete!
<<sRGB.icc>> (d:/Program Files/texlive/2020/texmf-dist/tex/latex/pdfx/8bit.def
File: 8bit.def 2008/03/30 v1.1d Input encoding file
Package hyperref Info: Option `unicode' set `true' on input line 2411.
Package hyperref Info: Option `unicode' set `true' on input line 2412.

(d:/Program Files/texlive/2020/texmf-dist/tex/generic/pdftex/glyphtounicode.tex
(d:/Program Files/texlive/2020/texmf-dist/tex/latex/pdfx/glyphtounicode-cmr.tex
(d:/Program Files/texlive/2020/texmf-dist/tex/latex/pdfx/glyphtounicode-ntx.tex
) (d:/Program Files/texlive/2020/texmf-dist/tex/latex/base/ifthen.sty
Package: ifthen 2014/09/29 v1.1c Standard LaTeX ifthen package (DPC)
(d:/Program Files/texlive/2020/texmf-dist/tex/latex/xmpincl/xmpincl.sty
Package: xmpincl 2008/05/10 v2.2 Include XMP data in pdflatex
(d:/Program Files/texlive/2020/texmf-dist/tex/latex/pdfx/8bit.def
File: 8bit.def 2008/03/30 v1.1d Input encoding file
Using XMP template file: pdfa.xmp
\openout3 = `pdfa.xmpi'.

(d:/Program Files/texlive/2020/texmf-dist/tex/latex/base/inputenc.sty
Package: inputenc 2018/08/11 v1.3c Input encoding file
(d:/Program Files/texlive/2020/texmf-dist/tex/latex/psnfss/helvet.sty
Package: helvet 2020/03/25 PSNFSS-v9.3 (WaS) 
(d:/Program Files/texlive/2020/texmf-dist/tex/latex/base/fontenc.sty
Package: fontenc 2020/02/11 v2.0o Standard LaTeX package
(d:/Program Files/texlive/2020/texmf-dist/tex/latex/geometry/geometry.sty
Package: geometry 2020/01/02 v5.9 Page Geometry

(d:/Program Files/texlive/2020/texmf-dist/tex/generic/iftex/ifvtex.sty
Package: ifvtex 2019/10/25 v1.7 ifvtex legacy package. Use iftex instead.
(d:/Program Files/texlive/2020/texmf-dist/tex/latex/fancyhdr/fancyhdr.sty
Package: fancyhdr 2019/01/31 v3.10 Extensive control of page headers and footer
(d:/Program Files/texlive/2020/texmf-dist/tex/latex/titlesec/titlesec.sty
Package: titlesec 2019/10/16 v2.13 Sectioning titles
(d:/Program Files/texlive/2020/texmf-dist/tex/latex/setspace/setspace.sty
Package: setspace 2011/12/19 v6.7a set line spacing
(d:/Program Files/texlive/2020/texmf-dist/tex/latex/parskip/parskip.sty
Package: parskip 2020-06-15 v2.0f non-zero parskip adjustments

(d:/Program Files/texlive/2020/texmf-dist/tex/latex/etoolbox/etoolbox.sty
Package: etoolbox 2020/08/24 v2.5j e-TeX tools for LaTeX (JAW)

(d:/Program Files/texlive/2020/texmf-dist/tex/generic/babel/babel.sty
Package: babel 2020/09/01 3.48 The Babel package

(d:/Program Files/texlive/2020/texmf-dist/tex/generic/babel/babel.def
File: babel.def 2020/09/01 3.48 Babel common definitions

(d:/Program Files/texlive/2020/texmf-dist/tex/generic/babel/txtbabel.def)

(d:/Program Files/texlive/2020/texmf-dist/tex/generic/babel-english/english.ldf
Language: english 2017/06/06 v3.3r English support from the babel system
Package babel Info: \l@canadian = using hyphenrules for english
(babel)             (\language0) on input line 102.
Package babel Info: \l@australian = using hyphenrules for ukenglish
(babel)             (\language21) on input line 105.
Package babel Info: \l@newzealand = using hyphenrules for ukenglish
(babel)             (\language21) on input line 108.
(d:/Program Files/texlive/2020/texmf-dist/tex/generic/babel-finnish/finnish.ldf
Language: finnish 2020/04/16 v1.3r Finnish support from the babel system
Package babel Info: Making " an active character on input line 85.
)) (d:/Program Files/texlive/2020/texmf-dist/tex/latex/csquotes/csquotes.sty
Package: csquotes 2019-12-06 v5.2j context-sensitive quotations (JAW)

(d:/Program Files/texlive/2020/texmf-dist/tex/latex/csquotes/csquotes.def
File: csquotes.def 2019-12-06 v5.2j csquotes generic definitions (JAW)
Package csquotes Info: Trying to load configuration file 'csquotes.cfg'...
Package csquotes Info: ... configuration file loaded successfully.

(d:/Program Files/texlive/2020/texmf-dist/tex/latex/csquotes/csquotes.cfg
File: csquotes.cfg 
(d:/Program Files/texlive/2020/texmf-dist/tex/latex/datetime2/datetime2.sty
Package: datetime2 2020/03/02 v1.5.6 (NLCT) date and time formats

(d:/Program Files/texlive/2020/texmf-dist/tex/latex/tracklang/tracklang.sty
Package: tracklang 2020/06/30 v1.5 (NLCT) Track Languages

(d:/Program Files/texlive/2020/texmf-dist/tex/generic/tracklang/tracklang.tex))
(d:/Program Files/texlive/2020/texmf-dist/tex/latex/xkeyval/xkeyval.sty
Package: xkeyval 2014/12/03 v2.7a package option processing (HA)

(d:/Program Files/texlive/2020/texmf-dist/tex/generic/xkeyval/xkeyval.tex
(d:/Program Files/texlive/2020/texmf-dist/tex/generic/xkeyval/xkvutils.tex
File: xkeyval.tex 2014/12/03 v2.7a key=value parser (HA)
(d:/Program Files/texlive/2020/texmf-dist/tex/latex/datetime2-finnish/datetime2
File: datetime2-finnish.ldf 2018/03/20 v1.2

(d:/Program Files/texlive/2020/texmf-dist/tex/latex/datetime2-finnish/datetime2
File: datetime2-finnish-ascii.ldf 2018/03/20 v1.2
(d:/Program Files/texlive/2020/texmf-dist/tex/latex/datetime2-english/datetime2
File: datetime2-english.ldf 2019/10/21 v1.05 (NLCT)

(d:/Program Files/texlive/2020/texmf-dist/tex/latex/datetime2-english/datetime2
File: datetime2-english-base.ldf 2019/10/21 v1.05 (NLCT)
(d:/Program Files/texlive/2020/texmf-dist/tex/latex/datetime2-english/datetime2
File: datetime2-en-GB.ldf 2019/10/21 v1.05 (NLCT)
(d:/Program Files/texlive/2020/texmf-dist/tex/latex/biblatex/biblatex.sty
Package: biblatex 2020/08/23 v3.15a programmable bibliographies (PK/MW)

(d:/Program Files/texlive/2020/texmf-dist/tex/latex/logreq/logreq.sty
Package: logreq 2010/08/04 v1.0 xml request logger

(d:/Program Files/texlive/2020/texmf-dist/tex/latex/logreq/logreq.def
File: logreq.def 2010/08/04 v1.0 logreq spec v1.0

! Text line contains an invalid character.
l.2175      \bgroup\nohyphenation#1\egroup^^^
? X
Here is how much of TeX's memory you used:
 19886 strings out of 480875
 320003 string characters out of 5904580
 566727 words of memory out of 5000000
 35302 multiletter control sequences out of 15000+600000
 536150 words of font info for 31 fonts, out of 8000000 for 9000
 1141 hyphenation exceptions out of 8191
 61i,0n,52p,908b,4779s stack positions out of 5000i,500n,10000p,200000b,80000s
No pages of output.

pdfTeX warning: pdflatex.exe: dangling objects discarded, no output file produc

PDF statistics:
 3 PDF objects out of 1000 (max. 8388607)
 0 named destinations out of 1000 (max. 500000)
 13 words of extra memory for PDF output out of 10000 (max. 10000000)
  • You can accept an answer by clicking on the green checkmark on the top left of the post. See also tex.stackexchange.com/help/someone-answers. Generally it is preferred to mark question as resolved by accepting an answer rather than by editing the title to include the word '(re)solved'. (One of my first interactions on SE ended with me editing 'solved' into the title, it was removed within a minute.)
    – moewe
    Oct 2, 2020 at 6:28

2 Answers 2


This is an unfortunate side effect of using the pdfx package.

A simpler example is







You could make the catcode of character 30 normal (12) rather than invalid (15)





  • That did the trick!
    – gigablob
    Oct 1, 2020 at 19:49

This issue was also reported at the biblatex bugtracker (https://github.com/plk/biblatex/issues/1044) and should be resolved on the biblatex side in the upcoming biblatex release.

The workaround biblatex now uses to avoid the problem is to isolate the problematic ^^^^200b to a file that is only read by the Unicode engines, where it is apparently not disallowed by pdfx/\UseRawInputEncoding.

  • thanks for avoiding this in biblatex, pdflatex sees ^^^ as control-^ which is character 30 which pdfx makes invalid... Oct 1, 2020 at 20:19
  • Well, it is not coding in pdfx that makes it invalid, but LaTeX coding from use of \UseRawInputEncoding . With a name like RawInputEncoding one would naturally think that all characters would be recognised, but that is not so, as many are set to catcode 15 = invalid. What then is the real purpose of \UseRawInputEncoding ?
    – Ross Moore
    Oct 2, 2020 at 0:03
  • @RossMoore As documented, it restores the catcode situation prior to the move to default-UTF8 in 2018. That means one treats files 'raw'. I'm very surprised it's used in pdfx: the command is for users processing older files that relied on undocumented behaviours (that parts of the upper half of the 8-bit range happened to work for some people without loading inputenc).
    – Joseph Wright
    Oct 2, 2020 at 6:57
  • @JosephWright. But it's lower bytes in the range < 32 that is the issue here. Many are made unavailable (catcode 15). How is that 'raw'? It's the name here that has led me to think this was appropriate, whatever version of LaTeX is being used. Clearly it is not, and I can program those catcodes to be reset after reading the .xmpdata file.
    – Ross Moore
    Oct 18, 2020 at 23:45

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.