-
Notifications
You must be signed in to change notification settings - Fork 19
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
BiocStyle and png image not usable in the same document #42
Comments
Thanks for reporting. I'm not sure what could be the cause of the error an whether it is related to #32. It would be great if you could paste the contents of
|
This is located in the %appdata%/../Local/Temp folder instead of the working directory next to the .Rmd file. In comparison, the default file (from |
Thanks, could you maybe paste the output of running |
versus
|
Great, thanks a lot! One last thing: does setting |
It fails. So it is a bookdown problem... I didn't know about that debugging option.
|
Thanks for your help on this. Indeed, it seems to be bookdown-specific problem, please consider reporting it at https://github.com/rstudio/bookdown/issues. |
Hi @aoles you might want to have a look at the bookdown issue. It is becoming a bit weird, since with TinyTeX the image works, but the BiocStyle format does not. I am now really out of my depth here. PS: Ubuntu + R 3.4.3 works as well. so it is not a R-devel solution/problem. |
Thanks for trying TinyTeX. Are you absolutely sure the observed PDF is the result of compiling a document with |
Oh, caching... What was quoted to me again not long ago:
You were right: caching issue. The test.pdf was created by a previous run and therefore no error was thrown. I redid it know several time, with removing all(?) caches I could find. Here is the output using BiocStyle::pdf_document:
edit: Now this fails even without the image. Tomorrow I can test again with MiKTeX. |
Thanks! Did you try compiling the resulting |
That returns
|
It seems to fail on the following error reported in
Did you try to resolve it? |
Not really. To get from the image specific behaviour using MiKTeX (bookdown + BiocStyle) to the BiocStyle only but image independent issue with TinyTeX took me some time. From the rmarkdown::render output it seams that some file are not correctly found #42 (comment)
But the search is triggered within every run and it states that the package is already present. With bookdown the error does not appear, so I am back at the beginning, suggesting that it is indeed a BiocStyle issue. Two files are present in I am sorry that this is so laborious, but I am out of my depth a bit. Tomorrow I can try again using MiKTeX again (have to delete TinyTeX first) and with TinyTeX on a different machine. |
@FelixErnst I don't know why it keeps installing the ec package; ec is included in TinyTeX by default. Can you delete test.log and retry? FWIW, I just tried it on Windows and could not reproduce the LaTeX issue here (about the missing ec package). |
I triggered a reinstall of ec using
The problem persists. I am now at home and will try at work tomorrow on a different machine (the error appeared there first) by removing MiKTeX and using TinyTeX |
So first things first: I uninstalled MiKTeX an tried with TinyTeX first. bookdown works out of the box without the image. With image it fails with the error With the image BiocStyle failed the same way as bookdown. Without the image this error message appeared in the rmarkdown log:
It is more verbose than at home, but the error is the same So i think will just leave it at that. @aoles @yihui Thanks for the help and patience, but this is becoming to time consuming for me. It appears to be machine specific or not and the inconsistency with the LaTeX just makes it more than painful. |
so after I took a breath> On my machine at work the problem with image is that the temp folder is created inside %appdata%/Local/Temp folder instead next to the Rmd document. If I put the image.png next to the generate tex file in %appdata%/Local/Temp and try to compile the pdf with rstudio, the error about the image is gone and the creation fails again with the same error about the ecrm1000 font as described above.
Thanks again. |
So it gets even better: The image issue is due to the fact that the .Rmd file with the image was located on drive D:. Moving it and the image to C:\ solved the problem of the image not being found. The reason behind this is, that the temporary tex file is created next to the .Rmd file, if on drive C:\ and in %appdata%\Local\Temp if on drive D:. At home I head the file on drive C:\ so the image issue never occurred. Before I checked at home, I switched from MiKTex to TinyTeX confusing me regarding cause and effect. So this leaves just the ecrm1000 font file not being found, when using TinyTeX. |
So now I come full circle: Using BiocStyle and MiKTeX complete works, if the .Rmd file is on drive C:. On drive D:\ it fails, since the temp files end up in another folder. MiKTeX basic and TinyTeX fail with the font error. |
@FelixErnst Sorry for adding another issue (TinyTeX) that seems to be irrelevant to your original issue, but how did you install TinyTeX? You are expected to install it with: devtools::install_github(c('yihui/tinytex', 'rstudio/rmarkdown'))
tinytex::install_tinytex() Another thing we still haven't figured out is whether this is a bookdown or BiocStyle issue. Since MiKTeX does not have the ec problem, you can stay with MiKTeX for now (we can figure out the TinyTeX issue later). You just need to check if changing |
@yihui Well it is more complicated than that apparently. I tried to minimize the scenario further and figured out, that somehow the RStudio project files were responsible for the different behavior regarding .Rmd files. It is not apparently not a C/D drive problem, but an inside/outside problem regarding the project folder. Deleting the .Rproj file did not solve the problem, but deleting the hidden .Rproj.user folder did. I tried to figure what files in this folder, where causing the image problem (aka. what triggered the generated tex files to be created in the %appdata%/Local/Temp folder), but there were so many that I just removed the .Rproj file and folder. That solved the issues regarding the image (Who what have thought about that...). Before you ask: I never touched the RStudio settings via the gui, so I don't know how that behavior got triggered. Regarding TinyTeX: I used the bat file and after restarting RStudio It is as BiocStyle/TinyTeX issue. |
Thanks a lot @FelixErnst for investing so much time and effort into debugging this - I really appreciate your determination. Regarding the image file issue when compiling documents managed as R Studio projects: I've already noticed this before that apparently .Rmd files under The problem with ecrm1000 seems to be specific to your LaTeX configuration. It is not a direct problem with BiocStyle in the sense that it fails only during the final step of compiling the output .tex source, and the same source would build just fine on other machines (as long the path to Biocstyle.sty is adjusted accordingly). So I guess there is not much I can do on my side to fix this. |
does not work. On Windows 10 64 bit 16299.214 / RStudio 1.1.423 / R 3.4.3 knitting the document reports
! Package pdftex.def Error: File image.png not found: using draft setting.
Changingoutput: pdf_document
solves the issue and a pdf is successfully created.The original file with BiocStyle:: works under Ubuntu 17.10 / RStudio 1.1.423 / R-devel. Was this solved with the #32 issue or is it caused by something else?
I am sorry, but I don't have the expertise to install R-devel under Windows, so I cannot test that. Can you give me hint, whether this problem is fixed in R-devel?
The text was updated successfully, but these errors were encountered: