fhackenberger / ktikz

KtikZ provides a nice user interface for making pictures using TikZ.
Other
348 stars 34 forks source link

tmp log file naming problem #44

Open ea42gh opened 4 years ago

ea42gh commented 4 years ago

trying to run a simple example results in

[LaTeX] Error: run failed.
Command: pdflatex -halt-on-error -file-line-error -interaction nonstopmode -output-directory /tmp/ktikz-uoXhgU /tmp/ktikz-uoXhgU/temptikzcode.tex
[LaTeX] Warning: could not load LaTeX log file.
Log file: /tmp/ktikz-uoXhgU/temptikzcode.log

ls /tmp/ktikz-uoXhgU/ shows temptikzcode.pgf texput.log any quick fix? I guess I could wrap the call in a script and move the log file...

kaushikcfd commented 4 years ago

I hit this too. My current (ugly) workaround is launching sudo ktikz from the terminal.

jfmcarreira commented 3 years ago

That is strange. I got the files and they have correct owner and permissions.

I never saw this error. Could you please you run "ls -l" in the temporary directory.

kaushikcfd commented 3 years ago

@jfmcarreira: ls -l in /tmp works fine. Some more info: Running Ubuntu 20.04, Kitkz 0.12

jfmcarreira commented 3 years ago

I mean ls -l /tmp/ktikz-uoXhgU/ and post the result here, so I can see the permissions of the files created.

kaushikcfd commented 3 years ago

For the log:

[LaTeX] Error: run failed.
Command: pdflatex -shell-escape -halt-on-error -file-line-error -interaction nonstopmode -output-directory /tmp/ktikz-JWownQ /tmp/ktikz-JWownQ/temptikzcode.tex
[LaTeX] Warning: could not load LaTeX log file.
Log file: /tmp/ktikz-JWownQ/temptikzcode.log
$ ls -l /tmp/ktikz-JWownQ/
total 8
-rw-rw-r-- 1 kaushikcfd kaushikcfd  68 Nov 25 15:59 temptikzcode.pgf
-rw-rw-r-- 1 kaushikcfd kaushikcfd 809 Nov 25 15:59 texput.log
spapadim commented 1 year ago

Apologies for necropost, but I get the same behavior. For some reason, the constructed commandline uses .tex extension but temp file is saved as .pgf (so, since TeX doesn't find input, it produces default log name texput.log). Issue title is a bit misleading but that seems to be case here as well...

spapadim commented 1 year ago

Answering my own question (after some digging through source code) with a workaround, in case anyone else encounters this: deleting text/x-pgf from the MimeType field of qtikz.desktop (so only text/x-tex remains) makes the problem go away.

FWIW, this is with qtikz DEB from the Ubuntu 20.04 official repos (0.12+ds1-3build1), running under Gnome; haven't tried ktikz.