I came across a strange error today with a simple beamer frame that I am pretty sure worked a few weeks ago.
It seems to boil down (again) to active characters, which is something that \usetikzlibrary{babel}
aims to fix. But here it is the other way around: if the library is used, it produces an error (File ended while scanning use of \pgfplots@addplotimpl@table@fromfile
), while there is no problem when it is not used...
Interestingly, if the \begin{frame}...\end{frame}
is removed, everything goes smoothly.
P.S. Older related posts do not seem to answer the problem...
This one deals with tikzmark
:
Clash between tikzmark, babel package (french) and babel tikzlibrary
This one deals with etoolbox
: Conflict between french option, babel package, babel tikzlibrary and etoolbox package
MWE:
\documentclass{beamer}
\usepackage[french]{babel}
\usepackage{pgfplots}
\usetikzlibrary{babel} % No problem if commented
\begin{filecontents*}{test.csv}
a,b,c,d,e
1,2,3,4,5
1,2,3,4,5
1,2,3,4,5
1,2,3,4,5
\end{filecontents*}
\begin{document}
\begin{frame} % Also no problem if commented!?
\begin{tikzpicture}
\begin{axis}
\addplot table[col sep=comma, x expr=\coordindex, y=a]{test.csv};
\end{axis}
\end{tikzpicture}
\end{frame} % Also no problem if commented!?
\end{document}
french
to a different language it also worksshorthands=off
to the babel options also works.