0

immediately after I added the mhchem package (version 4) into my document on overleaf, this error message popped up. Does anyone have any ideas as to why this error occurring, and what it's saying? (this message pops up on a mimimum-working-example that doesn't even have 42 input lines.

/usr/local/texlive/2017/texmf-dist/tex/latex/l3kernel/l3regex.sty, line 42 Package l3regex Warning: This package is obsolete --- use 'expl3' instead on input line 42.

Thanks

Edit: as LianTze Lim and Marijn pointed out, this was not an error message but instead a warning message.

  • In older versions of the LaTeX3 programming API (expl3), modules were split across many packages, e.g. regex functions reside in the l3regex package. Because of a lot of depencencies between those packages it became tedious to figure out the correct loading order, so all these modules were put into one huge package expl3 which loads all of them at once. So the message tells you to just use \usepackage{expl3} instead of loading each of those expl3 packages separately. – siracusa Sep 9 at 2:16
  • 2
    [Disclaimer: I'm a support personnel at Overleaf] We're currently testing TeX Live 2018 on Overleaf. If this warning bothers you, you can email support@overleaf.com with your project's URL, and we can set it to use TeX Live 2018 instead—this warning will then go away. – LianTze Lim Sep 9 at 2:21
  • @LianTzeLim thanks for the reply! I'm just curious, what are the changes being made to the current version of TeX Live (I assume you don't mean 2018 in one of the 2 times you said it) that make this warning appear? siracusa gave a great explanation but \usepackage{expl3} didn't make the warning message go away either. – David Lu Sep 9 at 4:05
  • 2
    At present, projects on Overleaf use TeX Live 2017 as the default, where the versions of mhchem and expl3 give rise to the warning message you saw. These packages have been updated in TeX Live 2018 so they are now compatible with each other—hence no warnings. – LianTze Lim Sep 9 at 5:59
  • 1
    And Yes I do mean TeX Live 2018; we're first deploying TeX Live 2018 on Overleaf, and then TeX Live 2019 later on. – LianTze Lim Sep 9 at 6:00
4

The package mhchem loads the package l3regex, internally. This package, when loaded, says that it is better to use the l3expl package instead.

A bit of history.

Many years ago, some brave souls started to code LaTeX3, "a long-term research project to develop the next version of the LaTeX typesetting system". The core of their work was the package expl3. "Expl" stands for "experimental". The experiment profed so successful that they did not dare to change the package name, later on. Around the expl3 core, a lot of other experiments were started, among others the l3regex package (standing for "LaTeX3 regular expressions"). mhchem makes use of that package. At some point in time, the LaTeX3 developers decided that they have too many packages and that it would make sense to consolidate them all into expl3, so that a user does not need to load so many packages (possibly in a very specific order). So, they moved all the functionality into expl3 and, at the same time, added a warning into l3regex so that users would know (but the package is still functional). Following that, the mhchem package was fairly quickly updated to use expl3 only instead of l3regex. Unfortunately, a widely-used distribution of package (TeXLive 2017?) included l3regex with the warning and mhchem in the old version still using l3regex. Since years, this has been given users a warning when using mhchem that they oftentimes do not understand. I really hope this distribution will fall out-of-use, eventually.

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.