Tinytex: Installing texlive packages fails after TeXLive 2021 release

Created on 2 Apr 2021  路  7Comments  路  Source: yihui/tinytex

This was working yesterday, but now it fails. I think TeXLive 2021 was released today?

> tinytex::install_tinytex() #OK 
> tinytex::tlmgr_install('a4wide')
tlmgr install a4wide

tlmgr: Local TeX Live (2020) is older than remote repository (2021).
Cross release updates are only supported with
  update-tlmgr-latest(.sh/.exe) --update
See https://tug.org/texlive/upgrade.html for details.
tlmgr install a4wide

tlmgr: Local TeX Live (2020) is older than remote repository (2021).
Cross release updates are only supported with
  update-tlmgr-latest(.sh/.exe) --update
See https://tug.org/texlive/upgrade.html for details.

@maelle

Most helpful comment

The most complicated thing is the CTAN mirrors---tlmgr chooses a random (fastest) mirror each time, so you could have installed TeX Live 2021 successfully with install_tinytex(), but tlmgr_install() could install packages from another CRAN mirror that still has TeX Live 2020. Anyway, I'll look into these problems, although (a couple of days') time will cure them all.

I don't understand. It was my impression that the bundle that gets installed with install_tinytex() contains a build from https://github.com/yihui/tinytex-releases/releases, which currently has TeXLive 2020, and does not need texlive mirrors?

I always set a CTAN mirror in my CI that I know to be reliable, but it is not clear to me how this could work now the mirror has texlive 2021, but the tinytex bundles still have texlive 2020?

All 7 comments

Rather minimal example https://github.com/maelle/pdf-bookdown Compared to the starter book I added

  • A GHA workflow using pak, that builds the PDF book, and a DESCRIPTION file to go with this.
  • One package in preamble.tex that's not packaged in tinytex as far as I understand.

Failure https://github.com/maelle/pdf-bookdown/runs/2252801821?check_suite_focus=true

I noticed a similar failures in repos of mine whose GHA workflows used to work.

yes indeed. Thanks for the heads up on this !

TeXLive 2021 was release yesterday - it every 1st April I think. We don't have a TinyTeX prebuilt binary available for this version yet, and tinytex::install_tinytex() download the last prebuilt version of tinytex-release.

@yihui it seems the release date is 1st april each year (it is already announced 1st April for TexLive 2022) . Maybe we could schedule a build of TinyTeX release each year on the 2nd in addition to our monthly build ?

I believe we could have a build today - I let @yihui trigger one in https://github.com/yihui/tinytex-releases as he knows the infrastructure better.

It seems it could be possible to also make a function to update a current tlmgr install in this case using update-tlmgr-latest(.sh/.exe) --update, but the advice from TeX Live remains a clean new install https://www.tug.org/texlive/tlmgr.html

Yes, this happens yearly, but the date may not be the same every year. I do check this problem in tinytex::tlmgr_update() and suggest tinytex::reinstall_tinytex() in the message:

https://github.com/yihui/tinytex/blob/ab46c449edda4e1a3a49cdc3b239e454424703c4/R/tlmgr.R#L192
https://github.com/yihui/tinytex/blob/ab46c449edda4e1a3a49cdc3b239e454424703c4/R/tlmgr.R#L198-L216

I don't know why it didn't work in @jeroen's case.

In @maelle's case, which is an automated job, I need to think more about what to do, since the message won't be seen by a human until the error occurs.

The most complicated thing is the CTAN mirrors---tlmgr chooses a random (fastest) mirror each time, so you could have installed TeX Live 2021 successfully with install_tinytex(), but tlmgr_install() could install packages from another CTAN mirror that still has TeX Live 2020. Anyway, I'll look into these problems, although (a couple of days') time will cure them all.

The most complicated thing is the CTAN mirrors---tlmgr chooses a random (fastest) mirror each time, so you could have installed TeX Live 2021 successfully with install_tinytex(), but tlmgr_install() could install packages from another CRAN mirror that still has TeX Live 2020. Anyway, I'll look into these problems, although (a couple of days') time will cure them all.

I don't understand. It was my impression that the bundle that gets installed with install_tinytex() contains a build from https://github.com/yihui/tinytex-releases/releases, which currently has TeXLive 2020, and does not need texlive mirrors?

I always set a CTAN mirror in my CI that I know to be reliable, but it is not clear to me how this could work now the mirror has texlive 2021, but the tinytex bundles still have texlive 2020?

I don't understand. It was my impression that the bundle that gets installed with install_tinytex() contains a build from https://github.com/yihui/tinytex-releases/releases, which currently has TeXLive 2020, and does not need texlive mirrors?

By default, the bundle is not from tinytex-releases, but a daily build of TinyTeX. The tinytex-releases repo contains monthly releases of TinyTeX.

I always set a CTAN mirror in my CI that I know to be reliable

Setting a fixed CTAN mirror at the time of packaging TinyTeX can make sure that we can always successfully build the TinyTeX package (on the daily basis), so I have done that. Previously, the daily build could fail because of the random mirrors, and that's exactly what happened this time.

but it is not clear to me how this could work now the mirror has texlive 2021, but the tinytex bundles still have texlive 2020?

Basically, it was too late for you to set the mirror. I have to do that when running the installation script install-tl. Otherwise TinyTeX could be packaged with one mirror, but you switched to another mirror after TinyTeX is installed. My mirror could be older than yours, and then tlmgr won't be able to update or install packages.

For the record, I'm setting the illiniois.edu mirror (the same as your choice).

Anyway, as I said, this problem should disappear in one day or two (or sometimes a couple of hours). If only we had a CTAN mirror that is guaranteed to have the latest version of TeX Live as soon as a new version is released, we wouldn't run into this problem.

This problem seems indeed solved with the latest daily builds of tinytex.

Anyway, as I said, this problem should disappear in one day or two (or sometimes a couple of hours). If only we had a CTAN mirror that is guaranteed to have the latest version of TeX Live as soon as a new version is released, we wouldn't run into this problem.

Maybe not entirely. In practice there may be time in between when tinytex is installed, and when the latex file is rendered.

In the case of r-universe, we install tinytex our docker image to build R packages. The docker image is only updated once in a while, hence the tinytex installation in there may be several weeks/months old.

I guess I need to remember to rebuild this docker image every time a new version of texlive is released.

Was this page helpful?
0 / 5 - 0 ratings