Problem with install_packages and install_github

I am getting an error when trying to install pagedown and I keep on getting the same error whether I use install.packages or remotes::install_github :

> install.packages("pagedown")
Installing package into ‘C:/Users/??? ???/Documents/R/win-library/4.1’
(as ‘lib’ is unspecified)
also installing the dependency ‘websocket’

trying URL 'https://cran.rstudio.com/bin/windows/contrib/4.1/websocket_1.4.1.zip'
Content type 'application/zip' length 4077955 bytes (3.9 MB)
downloaded 3.9 MB

trying URL 'https://cran.rstudio.com/bin/windows/contrib/4.1/pagedown_0.16.zip'
Content type 'application/zip' length 306200 bytes (299 KB)
downloaded 299 KB

Error in install.packages : missing value where TRUE/FALSE needed

and

> remotes::install_github('rstudio/pagedown')
Downloading GitHub repo rstudio/pagedown@HEAD
Installing 1 packages: websocket
Installing package into ‘C:/Users/??? ???/Documents/R/win-library/4.1’
(as ‘lib’ is unspecified)
trying URL 'https://cran.rstudio.com/bin/windows/contrib/4.1/websocket_1.4.1.zip'
Content type 'application/zip' length 4077955 bytes (3.9 MB)
downloaded 3.9 MB

Error: Failed to install 'pagedown' from GitHub:
  missing value where TRUE/FALSE needed

Here is my sessionInfo:

R version 4.1.1 (2021-08-10)
Platform: x86_64-w64-mingw32/x64 (64-bit)
Running under: Windows 10 x64 (build 19042)

I'm not really sure what I'm getting wrong and would appreciate any help.

EDIT: added full output of the error

We need more information to help you out with this, can you please post the complete error message you get?

Thanks so much for the reminder -- I've edited the original post to include the full output

I have seen this problem only once, I couldn't identify the cause for sure but apparently was solved by reinstalling R completely, including the base package library. See this related topic

Ooofff. Though, thanks for the advice, @andresrcs!

I'll do a full reinstall -- actually, I'm just gonna reformat my pc since I was thinking of doing it anyway. This was just the straw that broke the camel's back.

This topic was automatically closed 7 days after the last reply. New replies are no longer allowed.

If you have a query related to it or one of the replies, start a new topic and refer back with a link.