Solve the problem that the URL cannot be opened when install_github installs the R package?

I recently installed the R package on github, and it often shows Error in utils::download.file(url, path, method = method, quiet = quiet, : 无法打开URL'https://api.github.com/repos/such errors. At first I thought it was a problem with the network. I couldn't change the network, climb the ladder, or shut down and restart.
image.png

I checked it online and said that R downloads the package through the IE browser by default, so you need to set the IE security option.

But, I haven't used IE for many years (but many official government websites operate by default IE, and how many browsers are required), what's the fuck is that IE itself has been upgraded to Edge, which claims to be the same as chrome Easy to use. But when I opened Edge, I didn’t find Internet options after searching for a long time. Some online tutorials said to open IE with three horizontal bars in the upper right corner, and some said to open IE in more tools, but none of them in my Edge (maybe Because it's relatively new)!

image.png

So I searched on my computer and found that there is no Internet Explorer. Finally found a reliable answer, that is: Win+R,输入inetcpl.cpl 直接打开Internet选项. After opening, check Use TLS 1.0, Use TLS 1.1, Use TLS 1.2 in Advanced.
image.png

Then you can download successfully.
image.png

Ref: https://github.com/r-lib/remotes/issues/130
https://bbs.pinggu.org/thread-6956865-1-1.html
How to find internet options in the latest version of Microsoft Edge-Microsoft Community

Guess you like

Origin blog.csdn.net/weixin_41792162/article/details/114886068