8

After recent update of longtable package (2021.05.07) I am getting the error:

Dimension too large. \end{longtabu}

Log:

! Dimension too large.
<to be read again> 
=
l.10 \end{longtabu}
             
I can't work with sizes bigger than about 19 feet.
Continue and I'll use the largest value I can.

MWE:

\documentclass{article}
\usepackage{longtable}%
\usepackage{tabu}%
\begin{document}
\begin{longtabu}  {llX}
a & b & c\\
\end{longtabu}
\end{document}
11
  • 1
    Coincidentally, I had an issue with tabu package today. Ulrike said it's broken. ref Jun 10, 2021 at 14:53
  • 1
    The problem is that longtable is actively maintained to fix issues; on the other hand, tabu has been buggy forever and unmaintained for several years.
    – egreg
    Jun 10, 2021 at 14:58
  • 4
    you probably also updated latex. tabu does lots of low-level tricks and every change in latex can make it fail in more places. Sorry but since years the advice is not to use this package, see the readme here github.com/tabu-issues-for-future-maintainer/tabu. Jun 10, 2021 at 15:38
  • 1
    I just tried 4.14,4.15 and 4.16 and tabu fails with all of them which is more understandable 4.14 had some re-organisation to cope with floats appearing on the same page (when older versions would run off the bottom of the page in some cases) Jun 10, 2021 at 16:34
  • 1
    Ulrike found that tabu was relying on me using box1 and failds now I allocate a longtable-specific box (to avoid clashes with other packages....) github.com/tabu-issues-for-future-maintainer/tabu/issues/26 Jun 10, 2021 at 19:58

2 Answers 2

12

tabu is unmaintained but as a short term fix you can force an old version of longtable to load

\documentclass{article}
\usepackage{longtable}[=v4.13]%
\usepackage{tabu}%
\begin{document}

\begin{longtabu}  {llX}
a & b & c\\
\end{longtabu}
\end{document}

The changes in longtable have been very minor and only addressing features that fairly obviously needed addressing, but apparently tabu was relying on an internal definition somewhere.


It turns out that specifically tabu is relying on longtable using the \box1 scratch register and fails now longtable allocates a box for its internal use (a change made to avoid conflicts with other packages, you can't win...) there is a patch at the tabu github

https://github.com/tabu-issues-for-future-maintainer/tabu/issues/26

4

The new LaTeX3 package tabularray is an alternative to the outdated tabu package. You can use tblr and longtblr environments with it.

\documentclass{article}
\usepackage{tabularray}
\begin{document}
\begin{longtblr}[
  caption = {Table Caption},
]{llX[2,c]X[3,r]}
\hline
  a & b & c & d \\
\hline
\end{longtblr}
\end{document}

enter image description here

2
  • Unfortunately, tabularray has substantially worse performance than tabu.
    – bb94
    Mar 12 at 20:37
  • I was in the same case, and I've discover this package, which brings together a lot of features seamlessly : X columns, longtable, border and cell colors, ... A must !
    – 3isenHeim
    May 26 at 10:34

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .