future() arguments for passing R options and environment variables

未关闭
#480 6 条评论 1 个 reaction 已指派 0 人 在 GitHub 查看

还没有人认领这个 Issue。

评估

难度
5/5
预计耗时
一周以上
新手友好度
35/100
Issue 类型
功能
描述清晰度
基本清楚
活跃度
停滞
技术栈
r

调研方向

首先审查 future() API 以及 future.apply 和 furrr 中的 map-reduce API,以了解当前如何传递参数。定义 R 选项和环境变量的预期处理方式,包括列出的两个保护问题,并确认这些 API 之间的接口是一致的。

由索引模型根据 Issue 内容生成。

描述

There are cases where one needs to customize options and environment variables used by the future. This can be done by explicitly setting those in the future expression, but that might be tedious, especially to make sure that they are unset afterward. Having future() do it for us is easier and avoids some code clutter. Here's one idea:

# Set env var 'FOO' with its currently set value, if set + set 'BAR' to "42"
f <- future(..., envvars = c("FOO", BAR = "42"))

# Set R options 'foo' with its currently set value, if set + set 'bar' to 42L
f <- future(..., options = c("foo", BAR = 42L))

These arguments should be exposed also in map-reduce APIs, e.g. future.apply and furrr.

Possible concerns

  • All types of options and environment variables should not be exported; is that something that future should monitor/protect again?
  • In R, certain environment variables must be set before launching R; is that something that future should monitor/protect again?
主要语言
R
星标
1k
派生
93
平均合并
2 天 4 小时
30 天内合并 PR
1

环境准备

  • 没有 Dockerfile 或 Docker Compose 文件
  • 没有 Pull Request 模板
  • 阅读贡献指南

从这里开始

  1. 先读完整个 Issue,再读项目的贡献指南。
  2. 在 Issue 下留言说明你要接手 —— 这能避免两个人做同样的事。
  3. Fork 仓库,在一个分支上完成修改。
  4. 提交 Pull Request,并在描述里引用这个 Issue 编号。

futureverse/future 的其他 Issue

查看 futureverse/future 的全部 Issue

相似的 Issue

更多 R Issue

把新 issue 发到你的邮箱

精选适合新手参与的 GitHub issue 摘要。