LaTeX error related to tcolorbox.sty not found

我与影子孤独终老i 提交于 2020-04-10 05:22:09

问题


I have a problem with LaTeX whenever I try to download the file in PDF. When I try to do that, it gives me the following error:

! LaTeX Error: File `tcolorbox.sty' not found.
Type X to quit or <RETURN> to proceed ,or enter new name.
(Default extension: sty)Enter file name:! Emergency stop.<read > \usepackage

I've already downloaded the tcolorbox zip file and dragged the directory into the tex/latex tree, as said in README file, but neither that worked.

Originally I used to try to download the pdf from Jupiter Notebook, but also that gave me an error:

nbconvert failed: PDF creating failed, captured latex output:
Failed to run "xelatex .\notebook.tex -quiet" command:
This is XeTeX, Version 3.14159265-2.6-0.999991 (TeX Live 2019/W32TeX) (preloaded format=xelatex)
 restricted \write18 enabled.
entering extended mode
! Undefined control sequence.
<*> .\notebook
              .tex -quiet
? 
! Emergency stop.
<*> .\notebook
              .tex -quiet
No pages of output.
Transcript written on ?.

Any suggestions?


回答1:


After installing tcolorbox using LaTex's package manager tlmgr, I was getting similar errors for other dependencies. The solution below worked for me on Ubuntu 18.04 (64 bit) via the terminal:

tlmgr update --all --self
tlmgr install tcolorbox
tlmgr install pgf
tlmgr install xcolor
tlmgr install environ
tlmgr install trimspaces
tlmgr install mathpazo
tlmgr install parskip
tlmgr install adjustbox
tlmgr install collectbox
tlmgr install eurosym
tlmgr install ecs
tlmgr install ucs
tlmgr install enumitem
tlmgr install ulem
tlmgr install mathrsfs
tlmgr install jknapltx rsfs

Also, rendering the document to PDF using the "export notebook as" option didn't work for me. I did it at the command line: jupyter nbconvert --to pdf my_document.ipynb. You may need to install nbconvert if you don't have it.

If missing other dependencies, keep running tlmgr install with the missing dependencies until it works. I haven't figured out yet to which packages those dependencies belong, so my apologies for the dirty fix.




回答2:


In addition to Oscar's answer, I also had to run:

sudo tlmgr install collection-fontsrecommended

and it worked



来源:https://stackoverflow.com/questions/59225719/latex-error-related-to-tcolorbox-sty-not-found

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!