Hi, I have the similar issue. Error creating notebook: duplicate label '...', when I try to use knitr’s code externalization, namely, knitr::read_chunk() in the notebook’s setup chunk.
I copied exactly what Yihui showed in his book: R Markdown: The Definitive Guide
example.Rmd
```{r setup}
knitr::read_chunk("example.R")
```
example.R
## ---- chunk
1 + 1
When I restart R and run all Chunks, it is good. However, when I try to save the notebook, the error pop up. I don't think I have any duplicate labels. Following is the image of my result.