【问题标题】:Roxygen getting cannot open file/permission denied/execution haltedRoxygen 无法打开文件/权限被拒绝/执行停止
【发布时间】:2019-06-29 16:30:59
【问题描述】:

所以我一直在尝试构建和加载一个包并且一直收到这个错误

devtools::document(roclets=c('rd', 'collate', 'namespace'))

Updating stat290.ass2 documentation
Loading stat290.ass2
Error in file(con, "r") : cannot open the connection
Calls: suppressPackageStartupMessages ... topic_add_examples -> read_lines -> <Anonymous> -> file
In addition: Warning message:
In file(con, "r") :
  cannot open file 'C:\Users\blah\Desktop\stat290.ass2': Permission denied
Execution halted

Exited with status 1.

我看过这些帖子作为参考:Roxygen Warning "cannot open the connection" "Permission Denied"https://github.com/klutometis/roxygen/issues/766,但他们说错误已被修复。我已经尝试删除并重新安装 devtools 和 roxygen2,但没有任何运气

【问题讨论】:

    标签: r devtools r-package roxygen


    【解决方案1】:

    我通过删除函数头部的 roxygen2 cmets 中的 @return@example 解决了这个问题,因为我没有为它们写任何内容。看来,如果你放了@XXX,你需要在它旁边填写信息,否则key缺少值,它会爆炸。

    我从错误 topic_add_examples -&gt; read_lines -&gt; 中得到了他的想法,因为它似乎试图读取我的 @example 旁边的 cmets,但我没有。

    【讨论】:

      猜你喜欢
      • 2023-03-11
      • 2013-01-22
      • 2011-10-16
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 2020-08-29
      • 2010-12-26
      相关资源
      最近更新 更多