-
-
Notifications
You must be signed in to change notification settings - Fork 2
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
Clearer error message? #9
Comments
Thanks for the bug report. So your issue is that you simply need to also load
So regarding the cryptic error, how are you compiling? In my case, if I compile in command line for instance I get: So you clearly see that they complain because I also tried on emacs and I get directly the Full code:
|
How are you compiling this document? I can maybe see it it is possible to print a better error message for this platform… or maybe you just need to click a small arrow to print the full error message? |
Thank you for your fast response! I did not think to check further errors, because it was working without CacheMe and I loaded I am working in TexStudio and use XeLatex with I found an error in the log in the folder
But in log of the main folder is on mention of the undefined control sequence. There is only:
|
So in command line, XeLaTeX does print the same error message as above when run in the command line, but I realized it is not written directly in the log file, so TexStudio does not print it. A quick woraround is just to compile in the command line or open the above .log file, but it is not really satisfactory. I will try to investigate how to solve this (maybe using a shell redirection to a file and printing this file directly in the log would do the job… but I am a bit worried by fact that redirections might be OS/shell dependent…). I asked this question for now. |
Thank you. And as mentioned, you can find the log in the log of the corresponding figure in the |
Ok, the error message is much clearer now (I tried to print the error line on the first line of the message, and the actual error is printed a few lines later), and looks like this in emacs, and it jumps directly at the good cacheme code block :
A similar message is also printed in If it is not the case, then you can now look at the .log file: This still need a bit of testing for windows, but for what I tried it should work out of the box. |
Yes. This error message is great now! :) Thank you again! |
I found another unclear error. But it appears with gnuplot. Shall I open a new issue? It has to do with the problem, that gnuplottex does not work when there are spaces in the filename. But then the only error is |
No, you can add it here. I realize that I should print a few lines before and after the error also to make it clearer. No log is created, really? Weird. Can you paste a MWE? |
Hm interesting. This code does provide a proper error message:
I called the file This code on the other hand, does not create a precise error message und also no log file:
|
The error messages sometimes gets not properly displayed in Texstudio. There I can only see
I don't know if this can be handled in robust-extrenalize. |
Found another unprecise error. If one tries to plot data in gnuplot but forgets to add the data file to the directory of main latex document, the error in texstudio is just
The code is:
To reproduce there is no file needed :) |
So the latest version should have better (and more configurable) error messages. But first:
Uhm, so the problem is that if the file contains a space, latex adds
So there are multiple issues/solutions:
and it will automatically add "error" in front of all lines, making them (at least the first part) readable in texstudio. For the full log: I let you try the newer version, hopefully you like it better. |
Wow, you fixed the space problem? I reported this bug to gnuplottex here, but I seemed hard work. I can confirm, spaces in names do work now :)
Yes, in the command line the gnuplot error is no shown, very niche. The robust-externalize log is perfekt now. It only shows the gnuplot error, if I am not mistaken. Great, thank you again! In Texstudio the message didn't change. The whole error message is in the main log, same as in command line. But Texstudio only seems to print this line And the whole error message is written two time in the main log, is this intended or is this because of the way the CacheMeCode gnuplot works? |
Yeah, I based my solution on https://tex.stackexchange.com/questions/418670/avoid-quotation-marks-when-using-jobname-or-currfilename
Great!
Have you tried typing:
? This is maybe precisely for texstudio so that it adds "Error" in front of any line.
I do write the small error message twice + the log to be sure the users cannot miss it ^^' For emacs it is important that the small error arrives before the log, otherwise you get moved to a non-existing file. And for people that compiles everything in one go without stopping at errors, I wanted the small error to appear first when scrolling from the end… hence this repetition:
Maybe a bad idea, not sure, but I guess it can't be harmful. |
And you reported this at gnuplottex, great.
Yes, should have mentioned that, sorry. The main log does look exactly the same, with or without that option. Does thexstudio need a ! in front of the error as well?
I don't mind. Just wanted to make sure it is intentional. |
Yes, my log looks like the. As you noticed, texstudio does not show it. Is it possible to just print the error from the robExt log? There at least is a waring. |
Yes sure, it is always possible to show the whole log. So I finally came with a different solution: since
and it will add
|
Your code example above should run without any problems. Was that intended? Yes, this is better now. It does not display the whole error, because a linebreak, I suppose. The original error is On the other hand, this leads to a error flooding, when I set the tkiz terminal in gnuplot and omit the word terminal. But you can not have everything. Thank you for your work! |
Ahah yes, since I had no gnuplot installed on my shell, I was using this code to test if I was indeed getting an error "you don't have gnuplot installed", sorry ^^'
Yes LaTeX and texstudio are really anoying. I'm trying to ask here if there is a better solution https://tex.stackexchange.com/questions/705502/message-add-symbol-in-front-of-new-lines-even-if-there-is-a-line-break but the best thing would be for texstudio to parse errors correctly (tried to ask here and I got a link to the github issue texstudio-org/texstudio#1410 and one told me:
Since it seems a quite common typo, now once you type
or by creating your own preset:
|
Argg in fact this creates nasty bugs to redefine
Ok, I got this error fixed as well… but with a dirty hack since I need also to separate the lines in the log by around 4 newlines otherwise texstudio does not consider them as different errors and just hide them… So the log is less nice, but at least you get nice errors directly in the document: I don't think I can do much better, for better error messages you need to urge texstudio to solve their bugs ^^' Let me know if it works for you, and if you discover nasty side effects I have not considered. |
No problem!
Texstudio seems to be a pain. I will not complain anymore. Thank you very much for trying so hard! I am still experiencing those nasty bugs. Did you revert to version? I am seeing lots of different errors. Here is one |
Ohhh sorry, I forgot to push the changes ^^' Yes, I also noticed this regression which was introduced when I added |
Great, thanks for your return! (yeah, I wrote a code to fix the broken lines as well) |
Great work. Thank you for all your work and fast response! :) |
This might also expand to the python preset. If there is an error in my python code the only error message in the main log is
The corresponding robust-extrernalize log is
I am using my custom python matplotlib, if that matters. Here is a mwe:
|
As I told you, for now python code should not be indented with LaTeX code, otherwise the output is basically really unpredictable. In particular, the code might never run, might produce an error, or might run after the |
Oh, I understad. Without indention it is showing the error messages. Sorry to have bothered you! |
First of all, thank you for this great package! I found a small issue.
If I escape a math environment inside a tikzpicture with
\text{…}
instead of\mathrm{…}
robust-externalize throws a cryptic error:Package robExt Error: The pdf file
. Without theCachMe
environment the tikzpicture is working fine.Here is my minimalistic example:
The text was updated successfully, but these errors were encountered: