Comments (5)
TL;DR It's the output of tidyverse_conflicts()
that seems to cause the error.
Can confirm error re. Unicode character (! LaTeX Error: Unicode character ^^[ (U+001B)
) using tinytex:
source input test-issue327.Rmd
(recreated below):
---
title: "Test"
output: pdf_document
date: "`r Sys.Date()`"
---
```{r setup, include=FALSE}
knitr::opts_chunk$set(echo = TRUE)
```
```{r}
library(tidyverse)
```
Output from render after updating tinytex with tinytex::tlmgr_update()
per recommendations at https://yihui.org/tinytex/r/#debugging:
|..................... | 40% (setup)
processing file: test-issue327.Rmd
/opt/homebrew/bin/pandoc +RTS -K512m -RTS test-issue327.knit.md --to latex --from markdown+autolink_bare_uris+tex_math_single_backslash --output test-issue327.tex --lua-filter /Users/maraaverick/Library/R/arm64/4.2/library/rmarkdown/rmarkdown/lua/pagebreak.lua --lua-filter /Users/maraaverick/Library/R/arm64/4.2/library/rmarkdown/rmarkdown/lua/latex-div.lua --embed-resources --standalone --highlight-style tango --pdf-engine pdflatex --variable graphics --variable 'geometry:margin=1in'
output file: test-issue327.knit.md
Backtrace:
x
1. \-rmarkdown::render(...)
2. \-rmarkdown:::latexmk(...)
3. \-tinytex::latexmk(file, engine, if (biblatex) "biber" else "bibtex")
4. \-tinytex:::latexmk_emu(...)
5. \-tinytex (local) run_engine()
6. +-tinytex:::system2_quiet(...)
7. \-tinytex (local) on_error()
8. \-tinytex:::show_latex_error(file, logfile)
! LaTeX Error: Unicode character ^^[ (U+001B)
not set up for use with LaTeX.
Error: LaTeX failed to compile test-issue327.tex. See https://yihui.org/tinytex/r/#debugging for debugging tips. See test-issue327.log for more info.
Execution halted
With options(tinytex.verbose = TRUE)
:
This is pdfTeX, Version 3.141592653-2.6-1.40.24 (TeX Live 2022) (preloaded format=pdflatex)
restricted \write18 enabled.
entering extended mode
I was unable to find any missing LaTeX packages from the error log test-issue327.log.
Backtrace:
x
1. \-rmarkdown::render(...)
2. \-rmarkdown:::latexmk(...)
3. \-tinytex::latexmk(file, engine, if (biblatex) "biber" else "bibtex")
4. \-tinytex:::latexmk_emu(...)
5. \-tinytex (local) run_engine()
6. +-tinytex:::system2_quiet(...)
7. \-tinytex (local) on_error()
8. \-tinytex:::show_latex_error(file, logfile)
! LaTeX Error: Unicode character ^^[ (U+001B)
not set up for use with LaTeX.
Error: LaTeX failed to compile test-issue327.tex. See https://yihui.org/tinytex/r/#debugging for debugging tips. See test-issue327.log for more info.
Execution halted
Everything knits fine with, say, library(dplyr)
, in place of library(tidyverse)
.
I am able to knit the file with messages and warnings turned off for the chunk with library(tidyverse)
(or with just message=FALSE
). Below knits to PDF fine:
---
title: "Test"
output: pdf_document
date: "`r Sys.Date()`"
---
```{r setup, include=FALSE}
knitr::opts_chunk$set(echo = TRUE)
options(tinytex.verbose = TRUE)
```
```{r message=FALSE, warning=FALSE}
library(tidyverse)
```
However, if the above Rmd has a chunk with tidyverse::tidyverse_conflicts()
in it, you get the same error:
```{r}
tidyverse::tidyverse_conflicts()
```
from tidyverse.
@batpigandme when I use message = FALSE
in the code chunk, it does work!
But I shouldn't have to put that to be able to knit something...
from tidyverse.
This is quite annoying. I have to hand-edit the tex file after each knit. I hope this will be fixed soon.
from tidyverse.
I think you're hitting r-lib/cli#581.
from tidyverse.
Two work arounds in the meantime:
- Install the dev version of cli:
pak::pak("r-lib/cli")
- Suppress the tidyverse loading message everywhere by adding this to your
.Rprofile
:options(tidyverse.quiet = TRUE)
from tidyverse.
Related Issues (20)
- Advertise conflicted HOT 1
- Make header more informative HOT 1
- Error: package or namespace load failed for ‘tidyverse’ HOT 10
- install (tidyverse) problem Rstudio 4.2.1 HOT 1
- install (tidyverse) problem Rstudio 4.2.1 HOT 2
- Make it easier to discover and exploit the `"tidyverse.quiet"` option
- Release tidyverse 2.0.0
- Upkeep for tidyverse HOT 2
- install problem -- Error in library(tidyverse) : there is no package called ‘tidyverse’ HOT 15
- Upkeep for tidyverse
- issue with group_by function HOT 1
- Tidyverse install HOT 2
- R changed its usual behavior causing entire code base to collapse HOT 1
- tidyverse installation fail on MacOS 10.11.6 el capitan HOT 5
- Upkeep for tidyverse (2023)
- Throw errors that better identify the user-facing function
- Unable to install packages on Ubuntu 20.04 HOT 1
- Could scales also be loaded within `library(tidyverse)`?
- Can't install Tidyverse package
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from tidyverse.