Search:   Help



LyX documentation


Shared groups




Categories: FAQ, Errors
<< | Page list | >>

Explanation of some common LaTeX errors

§1.  Too many unprocessed floats

LaTeX can handle only a limited number of floating elements floating at a given time. For example, if Figure 4 can't be fit in a good location (using the default rules of top of the page, then bottom, then a page of its own) and Figure 5 comes along, they will both continue to float toward the end of the document until a good location can be found. If nothing good turns up, they will just be placed at the end of the document. If there are too many of these, LaTeX overruns a counter and emits the "too many unprocessed floats" error. This is not a bug in LaTeX, this is simply too many figures with too little text :-)

The easiest way to work around this is to insert a \clearpage command somewhere in the document where a pagebreak would be appropriate. While a pagebreak would simply start a new page, \clearpage processes all remaining floats, then begins a new page. This may lead to an unsightly stack of figures in the middle of your document; you may need to use several \clearpages to make things balance nicely.

§2.  File "xxx.sty" not found

This means that a required LaTeX package is not installed on your system or not correctly configured. See the next question for a solution.

§3.  I have a problem with a missing LaTeX class (.cls) or style (.sty). What can I do?

(0) New installations on Windows: Miktex should be automatically installing missing packages. This stopped working at Lyx V2.?? or perhaps it was Miktex2.9 . The problem appears to be that Miktex does not setup a repository for automatic downloads when installed anymore (even though package manager can download manually). Bring up the Miktex Package Manager -> Change Package Repository -> Packages should be installed from the internet -> Connection Settings. Choose a repository. Now when you preview in Lyx, Windows will spring up asking you to allow Miktex to make changes, and you should see packages being installed on the lyx status line at the bottom.

(1) First, look if LaTeX finds this package. In a terminal, issue the command

  • kpsewhich <name>

(e.g. kpsewhich mystyle.sty or kpsewhich myclass.cls)

If a path is returned, the the file is installed and known to LaTeX. Proceed to step (3). If nothing is returned, go on with step (2).

(2) Install the package either via your LaTeX distribution's package manager (if you have TeXLive or MikTeX) or manually via CTAN.

Linux-specific note on installing packages: From time to time, I discover that there's a LaTeX package out there I'd like to use. Sometimes, I discover it from a suggestion or through a search, but then I have the problem that I don't know how best to install it. I could manually download the files from CTAN and put them in the right place, but that gets cumbersome, and there's usually an easier way. In fact, there's usually some texlive .deb package already in the repositories waiting for me to install it. The problem is I don't know which package to install in order to get the LaTeX packages I want. Fortunately, there's a debian utility called apt-file. It can be installed the typical way (e.g., $sudo apt-get install apt-file). Once installed (after running $sudo apt-file update), you can run a command like $apt-file search wrapfig.sty
I did just that, and it returned the following:
texlive-latex-extra: /usr/share/texmf-texlive/tex/latex/wrapfig/wrapfig.sty
which tells me that if I want to use wrapfig.sty, I need to have the package texlive-latex-extra installed, which can be done with the package manager (e.g., $sudo apt-get install texlive-latex-extra).

(3) Assure the TeX File Name Database is updated (usually by issuing the command texhash in administrator mode). Repeat step (1) to check if you succeeded.

(4) In LyX, run Tools→Reconfigure and restart LyX.

If this does not help, ask on the lyx-users list for help.

§4.  Font T1/cmr/m/it/6=ecti0600 at 6.0pt not loadable ...

If you get error messages of this kind:

 Font T1/cmr/m/it/6=ecti0600 at 6.0pt not loadable: Metric (TFM) file not found 

then, according to this thread, you probably do not have the permissions to operate in /var/cache/fonts/. The easiest solution is to add your user to the 'users' group; this will give you enough privileges to work on /var/cache/fonts/ and get your documents to compile. Refer to the discussion for more details

FAQ Errors

<< | FAQ.PageList | >>

Edit - History - Print - Recent Changes - All Recent Changes - Search
Page last modified on 2015-01-21 15:47 UTC