Unable to (fully) install tinytex

I'm having difficulties making tinytex work. I suspect it has to do with the corporate network I'm on.

I installed tinytex via:

> tinytex::install_tinytex(version = "latest")
trying URL 'https://github.com/rstudio/tinytex-releases/releases/download/v2024.01/TinyTeX-1-v2024.01.zip'
Content type 'application/octet-stream' length 129603486 bytes (123.6 MB)
downloaded 123.6 MB

3 File(s) copied
1 File(s) copied
Running fc-cache -v -r

When I try to render a Quarto qmd to pdf, the background process looks like this:

processing file: test.qmd
                                                                                                            
output file: test.knit.md

pandoc 
  to: latex
  output-file: test.tex
  standalone: true
  pdf-engine: xelatex
  variables:
    graphics: true
    tables: true
  default-image-extension: pdf
  
metadata
  documentclass: scrartcl
  classoption:
    - DIV=11
    - numbers=noendperiod
  papersize: letter
  header-includes:
    - '\KOMAoption{captions}{tableheading}'
  block-headings: true
  title: Untitled
  editor: visual
  
running xelatex - 1
  This is XeTeX, Version 3.141592653-2.6-0.999995 (TeX Live 2023) (preloaded format=xelatex)
   restricted \write18 enabled.
  entering extended mode
  
updating tlmgr

When I check the log, it indicates:

! LaTeX Error: File scrartcl.cls' not found.`

I then try to look for scrartcl.cls:

> tinytex::parse_packages("test.log")
tlmgr search --file --global "/scrartcl.cls"

character(0)
Warning message:
In tinytex::parse_packages("test.log") :
  Failed to find a package that contains scrartcl.cls

I tried a number of things, but it seems that the documentclass is not being installed properly.

I got this for the command

> tinytex::parse_packages(files = "scrartcl.cls")
tlmgr search --file --global "/scrartcl.cls"
[1] "koma-script"

The CLS should be part of koma-script. It should be included if you install with quarto install tinytex.
If you install with the R function, you need to choose a bundle with more already installed tool (GitHub - rstudio/tinytex-releases: Windows/macOS/Linux binaries and installation methods of TinyTeX). Otherwise it will try to download and install from the web

What should happen is that Quarto or R Markdown should detect the missing package and install for you. However, it tlmgr can't connect to the WEB then it won't work.

Downloading from R with install_tinytex() seems to have work - do you have a specific proxy configuration for your corporate environment so that R works ?

Maybe the same configuration should be put for TeX Live tlmgr too.

The fact that tlmgr search --file --global "/scrartcl.cls" returns nothing seems to indicate that it couldn't connect to CTAN repo maybe...

You can try tinytex::tlmgr_install("koma-script") and see if it install the missing package.

1 Like

Thank you. I uninstalled tinytex and tried reinstalling the quarto version. The first time it did not work because it was trying to connect and download from GitHub which my environment won't allow. I manually downloaded from GitHub and typed

quarto install tool tinytex C:\Users\username\Downloads\TinyTeX-v2024.01.zip

This seems to have worked

1 Like

This topic was automatically closed 45 days after the last reply. New replies are no longer allowed.

If you have a query related to it or one of the replies, start a new topic and refer back with a link.