Closed higgi13425 closed 5 years ago
Hmm, off the top of my head I think it may be a need to update the latex packages you have. Try using the tinytex
method to update all packages:
library(tinytex)
tlmgr_update()
Try that and let me know if it works or not!
Unfortunately, no luck with that intervention.
Error when knitting:
Quitting from lines 79-92 (test_kable.Rmd)
Error in dev.control(displaylist = if (record) "enable" else "inhibit") :
dev.control() called without an open graphics device
Calls:
Hmm, off the top of my head I think it may be a need to update the latex packages you have. Try using the tinytex method to update all packages:
library(tinytex)
tlmgr_update()
Try that and let me know if it works or not!
— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub, or mute the thread.
Alright, this appears to be a macOS specific issue, if you can confirm you are using macOS that ould be great. A few test options that could narrow it down:
1) Are you able to try knitting the document without any r chunks / no figures ?
2) Use capabilities()
to see if your install of R allows for cairo = TRUE
More data:1. Yes, a Mac desktop, though knitting works fine on my mac laptop (previously addresses issues with posterdown on that one). Seems like individual setup on Macs matters.1.a. removed figure chunks - able to knit.2. capabilities does say cairo=TRUE3. installed R 3.5.2 from CRAN, still knits fine if no figures, fails if even one figure added back.- reinstalled posterdown from GitHub - reinstalled tidy text4. Possibly a deficiency of Xquartz on the Mac - XQuartz
|
XQuartz
|
|
|
appears to be required for Cairo. Can knit other Rmd documents to pdf on this Mac Then downloaded/installed XQuartz 2.7.11, and restarted Mac, now everything knits.Will add as an issue for the readme.
On Sunday, January 27, 2019, 1:31:35 PM EST, Brent Thorne <notifications@github.com> wrote:
Alright, this appears to be a macOS specific issue, if you can confirm you are using macOS that ould be great. A few test options that could narrow it down:
Are you able to try knitting the document without any r chunks / no figures ?
Use capabilities() to see if your install of R allows for cairo = TRUE
It could be an issue with the R installation itself. On macOS you can end up with Homebrew version of R rather than the CRAN version of R. I deciphered this as best as I could from this conversation posted as an issue to the bookdown-chineese repo from @yihui
Might need to post an issue in rmarkdown/ see if there is an old issue with the same topics (I couldn't find one yet but it may be there).
— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub, or mute the thread.
Looks like it might be worth adding Mac-specific instructions for setup XQuartz was the missing piece for Cairo, even though capabilities() for cairo = true
For Mac setup,
Yes this would be useful to Mac users! I'll add this soon. Glad it worked :smile:
Hi Brent, Glad I got that sorted - it took me two separate Mac installs to find the patternto that problem (and remember the separate issues with Xquartz, tinytex, and competing tex installs).
Unrelated questions about fonts:
posterdown
!
what controls the font for posterdown
??|
Font typefaces
An online LaTeX editor that's easy to use. No installation, real-time collaboration, version control, hundreds o... |
|
|
On Sunday, January 27, 2019, 5:40:44 PM EST, Brent Thorne <notifications@github.com> wrote:
Yes this would be useful to Mac users! I'll add this soon. Glad it worked 😄
— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub, or mute the thread.
Looks like it might be worth adding Mac-specific instructions for setup XQuartz was the missing piece for Cairo, even though capabilities() for cairo = true
For Mac setup,
- Download Quartz X11 at https://www.xquartz.org , install, restart your Mac
- install.packages("Cairo")
- Test library(Cairo) - if this fails, start over (the rest is the same)
- install or update devtools
- install posterdown from GitHub
- install tinytex
Thank you for this! I followed your instructions and it worked like a charm. 👍
it is useful. in the same time, I need instead pandoc_args: -- chapter using --top-level-division=chapter
When I use the default posterdown template, I get knit failure, with the following message:
Error: package or namespace load failed for ‘Cairo’: .onLoad failed in loadNamespace() for 'Cairo', details: call: dyn.load(file, DLLpath = DLLpath, ...) error: unable to load shared object '/Library/Frameworks/R.framework/Versions/3.5/Resources/library/Cairo/libs/Cairo.so': dlopen(/Library/Frameworks/R.framework/Versions/3.5/Resources/library/Cairo/libs/Cairo.so, 6): Library not loaded: /opt/X11/lib/libfreetype.6.dylib Referenced from: /Library/Frameworks/R.framework/Versions/3.5/Resources/library/Cairo/libs/Cairo.so Reason: Incompatible library version: Cairo.so requires version 19.0.0 or later, but libfreetype.6.dylib provides version 18.0.0
Then re-installed Cairo, then when trying to call library(Cairo) from the console, I get the following error:
Appears to be some kind of conflict in Cairo - not sure why.
Not sure if this is directly the cause of failure to knit.