toolkit icon indicating copy to clipboard operation
toolkit copied to clipboard

Package minted Error: minted v3+ executable is not installed, is not added to PATH, or is not permitted with restricted shell escape

Open NonnoPinto opened this issue 10 months ago • 0 comments

Problem

I'm facing a minted issue similar to #298, but following that steps I still had the same issue.

I'm running latest overleaf-toolikt on wsl with Ubuntu on a windows 11 host.

C:\Users\User>wsl --version
Versione WSL: 2.3.24.0
Versione kernel: 5.15.153.1-2
Versione WSLg: 1.0.65
Versione MSRDC: 1.2.5620
Versione Direct3D: 1.611.1-81528511
Versione DXCore: 10.0.26100.1-240331-1435.ge-release
Versione di Windows: 10.0.26120.3281

Inside the Docker, I've a working version of tlmgr

gzago@GiovanniZago:~/overleaf-toolkit/bin$ docker exec sharelatex tlmgr --version
tlmgr revision 73493 (2025-01-17 23:28:29 +0100)
tlmgr using installation: /usr/local/texlive/2024
TeX Live (https://tug.org/texlive) version 2024

And same goes for minted

gzago@GiovanniZago:~/overleaf-toolkit/bin$ docker exec sharelatex tlmgr info minted
package:     minted
category:    Package
shortdesc:   Highlighted source code for LaTeX
longdesc:    The package that facilitates expressive syntax highlighting in LaTeX using the powerful Pygments library. The package also provides options to customize the highlighted source code output using fancyvrb.
installed:   Yes
revision:    73967
sizes:       run: 1437k, bin: 5k
relocatable: No
cat-version: 3.5.1
cat-license: lppl1.3c lppl1.3 bsd3
cat-topics:  listing verbatim synt-hlt
cat-related: texments verbments
cat-contact-repository: https://github.com/gpoore/minted
collection:  collection-latexextra

But still had the same issue, when compiling:

Package minted Error: minted v3+ executable is not installed, is not added to PATH, or is not permitted with restricted shell escape

Solution

The solution, for me, was to manullay install pip and latexminted inside the docker docker exec sharelatex apt-get install pip -y docker exec sharelatex pip install latexminted --break-system-packages

Doubt

Is this the right approach?

Thanks!

NonnoPinto avatar Mar 01 '25 00:03 NonnoPinto