27

Here is a MWE:

\documentclass{article}

\usepackage{hyperref}

\begin{document}

a

\end{document}

When I compile my document on the arxiv website, I get the following errors:

! LaTeX Error: Option clash for package hyperref.

... 

l.6 \begin
{document}
? 
! Emergency stop.
... 

l.6 \begin
{document}
No pages of output.
Transcript written on arXivSubmission.log.

Seems bizarre that having a single package in the preamble causes an error.

  • In my case it turns out that it was because I am using texlive 2018 version and arxiv is using 2016 version. So the bbl file I uploaded does not work for arxiv. In the end, instead of install texlive 2016, I uploaded my project to overleaf.com and compiled it there. This solves my problem. – ablmf Jan 30 at 14:31
24

When you use the document class article, arxiv additionally loads by default Babel, hyperref, hobsub-hyperref, hobsub-generic, keyval, ifxetex, kvoptions, url, rerunfilecheck, nameref, and gettitlestring (all from the texlive 2016 version).

This means that, oddly enough, arxiv would compile without trouble the following document:

\documentclass{article}

\begin{document}

\url{https://tex.stackexchange.com/q/329461/34551}

\end{document}

Even if it uses the \url macro without loading the url or hyperref packages. Of course, if you try to compile this document on your installation, you would get an error:

! Undefined control sequence.
l.5 \url

But arxiv processes it just fine, without throwing any error.

Hence, you have two options:

  1. Ignore the error. It occurs only the first time arxiv compile your document (it compiles it multiple times), and don't impact the rendering. But careful, for this error might hides other problems (cf. the comments on this thread).
  2. Remove the hyperref package from your preamble. This is an odd solution, since you won't be able to compile your document on your installation, but it works, i.e., the document is compiled without throwing an error.

EDIT


More help can be found at Arxiv's Considerations for TeX Submissions and at Common Mistakes that cause Automated Processing to Fail webpages. Also, reasons to submit the tex sources are listed at Why Submit the TeX/LaTeX Source?.

According to this source, starting 2017-02-09, ArXiV uses TeXLive 2016, after my answer was written, so I doubt it is in need of a modification.

  • 2
    Where did you find this information about what arXiv automatically loads? – RobertHannah89 Mar 24 '17 at 2:35
  • 3
    I just read the .log file, that they share with you in any cases. – Clément Mar 27 '17 at 13:24
  • I am using JMLR template which have own style file, and trying to upload the manuscript to arXiv. I have also removed hyperref from the manuscript but still I am getting the same error. – Vinod Kumar Chauhan Apr 20 at 14:03
  • I found the error for my case. Even after removing 'hyperref', the error message did not go but there were some missing files also. So when I added those files, it worked. (missing files have their own story but don't want to make things more complex. just want to say somehow eps was working so added pdf versions). – Vinod Kumar Chauhan Apr 20 at 14:49
  • It appears to me that arXiv has changed its configuration: After removing hyperref from my source, I get the expected "Undefined control sequence" error for url. This answer might be obsoleted and hence need an update. – Mario Apr 23 at 14:37

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.