Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Conflicts with parameter -shell-escape #70

Open
lukbukkit opened this issue Apr 7, 2023 · 2 comments
Open

Conflicts with parameter -shell-escape #70

lukbukkit opened this issue Apr 7, 2023 · 2 comments

Comments

@lukbukkit
Copy link

lukbukkit commented Apr 7, 2023

Hello,

This package sadly does not work if the parameter -shell-escape is passed to the LaTeX compiler. I've appended one of its error logs. Someone on StackOverflow had a similar issue: https://stackoverflow.com/q/55837846.

Is it possible to exclude the package's figures by default from \tikzexternalize? There is a workaround redefining the \todo command to achieve this manually: https://tex.stackexchange.com/a/50343.

Best wishes,
Lukas

===== 'mode=convert with system call': Invoking 'pdflatex -shell-escape -halt-o
n-error -interaction=batchmode -jobname "gfxcompiled/Thesis-figure9" "\def\tikz
externalrealjob{Thesis}\input{Thesis}"' ========
This is pdfTeX, Version 3.141592653-2.6-1.40.24 (TeX Live 2022) (preloaded format=pdflatex)
 \write18 enabled.
entering extended mode
system returned with code 256

! Package tikz Error: Sorry, the system call 'pdflatex -shell-escape -halt-on-e
rror -interaction=batchmode -jobname "gfxcompiled/Thesis-figure9" "\def\tikzext
ernalrealjob{Thesis}\input{Thesis}"' did NOT result in a usable output file 'gf
xcompiled/Thesis-figure9' (expected one of .pdf:.jpg:.jpeg:.png:). Please verif
y that you have enabled system calls. For pdflatex, this is 'pdflatex -shell-es
cape'. Sometimes it is also named 'write 18' or something like that. Or maybe t
he command simply failed? Error messages can be found in 'gfxcompiled/Thesis-fi
gure9.log'. If you continue now, I'll try to typeset the picture.

See the tikz package documentation for explanation.
Type  H <return>  for immediate help.
 ...

l.89 ...ew section, Feedback would be appreciated}


! Package pgf Error: No shape named `inText' is known.

See the pgf package documentation for explanation.
Type  H <return>  for immediate help.
 ...

l.89 ...ew section, Feedback would be appreciated}


! Package pgf Error: No shape named `inText' is known.

See the pgf package documentation for explanation.
Type  H <return>  for immediate help.
 ...

l.89 ...ew section, Feedback would be appreciated}


! Package pgf Error: No shape named `inText' is known.

See the pgf package documentation for explanation.
Type  H <return>  for immediate help.
 ...

l.89 ...ew section, Feedback would be appreciated}


! Package pgf Error: No shape named `inText' is known.

See the pgf package documentation for explanation.
Type  H <return>  for immediate help.
 ...

l.89 ...ew section, Feedback would be appreciated}


! Package pgf Error: No shape named `inNote' is known.

See the pgf package documentation for explanation.
Type  H <return>  for immediate help.
 ...

l.89 ...ew section, Feedback would be appreciated}


! Package pgf Error: No shape named `inText' is known.

See the pgf package documentation for explanation.
Type  H <return>  for immediate help.
 ...

l.89 ...ew section, Feedback would be appreciated}


! Package pgf Error: No shape named `inNote' is known.

See the pgf package documentation for explanation.
Type  H <return>  for immediate help.
 ...

l.89 ...ew section, Feedback would be appreciated}
@henrikmidtiby
Copy link
Owner

Thanks for the bug report. I have tried to recreate the issue with the following minimal example. The code below works with --shell-escape, but fails if line four is enabled (it is currently commented out). I assume that your issue looks something like this?

\documentclass{article}
\usepackage{todonotes}
\usetikzlibrary{external}
% \tikzexternalize[prefix=pics/]

\begin{document}
Hello world!
\todo{Test}
\end{document}

By introducing the workaround suggested in section 1.8.12 in the documentation, the following solution is found which works on my computer together with --shell-escape.

\documentclass{article}
\usepackage{todonotes}
\usetikzlibrary{external}
\tikzexternalize[prefix=pics/]

\newcommand{\ruggedtodo}[2][]{\tikzexternaldisable\todo[#1]{#2}\tikzexternalenable}

\begin{document}
Hello world!
\ruggedtodo{Test}
\end{document}

@lukbukkit
Copy link
Author

Yes that's exactly the issue. Would it be feasable to enable this behavior by default and add a option to disable it if required? I wasn't smart enough to search the manual and I guess other might run into the same problem.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants