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

Unable to use save_kable. Error reported. #862

Open
onecare-business-intelligence opened this issue Oct 10, 2024 · 1 comment
Open

Unable to use save_kable. Error reported. #862

onecare-business-intelligence opened this issue Oct 10, 2024 · 1 comment

Comments

@onecare-business-intelligence

When I use kable_save to save a table generated by kableExtra in png format I receive the following error.
Error: rsession-utf8.exe: GeometryDoesNotContainImage `C:\test.png' @ warning/attribute.c/GetImageBoundingBox/534

The error is received in RStudio and RGui on Windows 11 machine.

kable(mtcars[1:5, ], "html") %>%
  kable_styling("striped") %>%
  save_kable('test.png')

platform x86_64-w64-mingw32
arch x86_64
os mingw32
crt ucrt
system x86_64, mingw32
status
major 4
minor 4.0
year 2024
month 04
day 24
svn rev 86474
language R
version.string R version 4.4.0 (2024-04-24 ucrt)
nickname Puppy Cup

Windows 11 using kableExtra 1.4.0. The error I believe is in kableExtra and not R exe.
Thank you,
Phil,

@dmurdoch
Copy link
Collaborator

This works for me on MacOS. I'd guess the issue is with the webshot2 package on your machine, which save_kable() uses to produce the output. Does this produce a picture of the Shiny web page?

webshot2::webshot("https://github.com/rstudio/shiny", "test.png")

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