I am using Mac OS Monterey Version 12.4. When attempting to render Quarto, I see the following error:
Error in assignInNamespace("htmlPreserve", htmlPreserve, ns = "htmltools") :
could not find function "assignInNamespace"
Calls: .main -> source -> withVisible -> eval -> eval
Execution halted
Error in packageVersion("rmarkdown") :
could not find function "packageVersion"
Calls: cat -> paste0
Execution halted
Unable to locate an installed version of R.
Install R from https://cloud.r-project.org/
What I have done so far to try to address this issue:
Downloaded the latest versions of R (4.2.1), R Studio (2022/07, 1-554), and Quarto (1.0.38), and the rmarkdown package (2.14) [FYI, I just checked rmarkdown's package version with packageVersion - which the error claims is not loaded]
I suspect the issue is because I am working in a project located on a Box (i.e. in the cloud) directory. I am able to use R just fine in R Studio, so it must be a Quarto specific issue with accessing R when working in a cloud environment(?).
Elizabeths-MacBook-Pro:r elizabethdavis$ quarto check
[â] Checking Quarto installation......OK
Version: 1.0.38
Path: /Applications/quarto/bin
[â] Checking basic markdown render....OK
[â] Checking Python 3 installation....OK
Version: 3.8.9
Path: /Library/Developer/CommandLineTools/usr/bin/python3
Jupyter: (None)
Jupyter is not available in this Python installation.
Install with python3 -m pip install jupyter
(|) Checking R installation...........Error in packageVersion("rmarkdown") :
could not find function "packageVersion"
Calls: cat -> paste0
Execution halted
[â] Checking R installation...........(None)
Unable to locate an installed version of R.
Install R from https://cloud.r-project.org/
Thank you very much Christophe. I have downloaded the latest Quarto version, but I am still encountering the same issue. I don't believe I have either of the options you suggested set;
From the digging I have done, it looks like one possibility is that the error is to do with my PATH. However, when I have tried to manually set the PATH, it has not fixed the problem.
Hi,
Thank you! The output of utils::packageVersion("rmarkdown") is '2.14'.
And yes, same errors as before when I attempt to render the hello.qmd doc:
Error in assignInNamespace("htmlPreserve", htmlPreserve, ns = "htmltools") :
could not find function "assignInNamespace"
Calls: .main -> source -> withVisible -> eval -> eval
Execution halted
Error in packageVersion("rmarkdown") :
could not find function "packageVersion"
Calls: cat -> paste0
Execution halted
Unable to locate an installed version of R.
Install R from https://cloud.r-project.org/
I have redownloaded R a few times now to try to address this issue, and have not changed the download path. I wonder if it is something to do with administrative privileges on my machine, although as far as I know I have sole control over it- there are no other user accounts.
Thank you very much again for all of your assistance with this.
Thank you Christophe. I tried what you suggested, but it seemed like Quarto was still unable to locate my installation of R. I am really not sure how to fix the problem, but have "solved" it by rendering the documents using R Studio Cloud. I will test the IDE again after the next release of Quarto, to see if your fix has solved the problem.