【发布时间】:2020-08-13 02:30:24
【问题描述】:
我正在使用 RStudio,并尝试在我当前的项目中使用 packrat。 我点击复选框“将此项目使用 packrat”,然后按 OK,我从控制台获得以下输出:
> packrat::init()
Initializing packrat project in directory:
- "/Users/Ash/Dropbox/Uni/2014/Thesis/Code/R"
Adding these packages to packrat:
_
packrat 0.4.0.12
Fetching sources for packrat (0.4.0.12) ... Error in snapshotSources(project, activeRepos(project), allRecordsFlat) :
Errors occurred when fetching source files:
Error in untar2(tarfile, files, list, exdir, restore_times) :
incomplete block on file
我在此错误上找不到太多信息,但根据 this 代码(搜索错误字符串,文件块不完整),这似乎与意外的文件长度/大小有关。
我认为下载可能已损坏?但是我已经尝试了很多次了。
或者我没有正确的权限?但是项目文件在这里应该没有问题。
还有其他人遇到过这个问题吗?
【问题讨论】:
-
相关:我在尝试安装 devtools 时遇到了这个问题。尝试安装 curl 时上游失败,因为我没有安装 libcurl4 开发包。通过在 Ubuntu 上执行
sudo apt-get install libcurl4-openssl-dev解决了这个问题。