Closed earcanal closed 2 years ago
I'm having the same issue (with both text_stats
and readability
), and it seems to occur if I switch between open documents. I'm not sure how to write a reprex for that scenario. But I can replicate it by:
readability
on the active file (works as expected)readability
againI've had a look through the code an I can't understand why this happens.
This is a tricky one. We use knitr::kable to format the table for display in the console. Looking at discussions elsewhere of unexpected HTML output from that function, I see that updating to the most recent version of RStudio is typically the solution. Please try the preview version and let me know if that helps: https://www.rstudio.com/products/rstudio/download/preview/
Another possibility is that you have options set somewhere that change the way kable() behaves. Because making a table is a side-effect of the function it's tricky to pin down the things that control it's behavior
You're right Ben. Calling knitr::kable(head(mtcars[, 1:4]), "html")
directly causes the same bug. Updating to the latest preview doesn't fix this. I'll submit a bug to knitr. Thanks for looking at this, and for the great package.
Thanks for following up here and with knitr, I'll close this for now.
Describe the bug
The plugin sometimes writes raw HTML rather than the results in the console, e.g.
To Reproduce
I haven't established a way to reproduce this, but it happens frequently. Restarting the session is a temporary fix.
Expected behavior
Session Info