Hacktoberfest 2026:维护者为十月标记出来的 issue,仍然开放、适合新手。 浏览 Hacktoberfest issue

Doc: Extending Context/Runners/etc.

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

还没有人认领这个 Issue。

评估

难度
4/5
预计耗时
3-5 天
新手友好度
30/100
Issue 类型
文档
描述清晰度
需要澄清
活跃度
停滞
技术栈
python
领域
documentation

调研方向

Start with the existing fabric example and the Context, Config, and Runner extension points mentioned in the issue. Document the minimum implementation for each, including the Local wrapper and .invoke.yaml configuration example, then clarify task gathering, deferred execution, dynamic asynchronous commands, and completion checks for a slurm-style runner.

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

描述

I am trying to extend invoke to be able to run slurm jobs, and I am slowly figuring out what I need to extend from the example of fabric. It would be nice to have this documented somewhere for other developers. So my understanding is that a common setup is to extend:

  • Context: The main entity to initialize the work environment and provide a user interface
  • Config: To add your own configurations to be parsed from .invoke.yaml
  • Runner: To define how to run a command

The issue currently is that it is not clear what is the minimum that we need to implement in each class. An example that could help illustrate is maybe a wrapper over Local that takes a "Hello world" message from Config, prints this message before each task/command, and prints a similar message at the start of the context setup.

Is there a matrix/IRC/Discord room to get some quick pointers for these?


Similarly, but more specific to the goal of the slurm wrapper:

  • How can I gather the tasks before a run command? Is that done automatically?
  • Is it possible to prepare run steps or postpone the execution of run in a context?
  • In an asynchronous runner, can I dynamically add tasks/run command (dependent or independent on a previous step)
  • For an asynchronous runner, where do I specify how to query if a run is finished or not?
主要语言
Python
星标
4.8k
派生
412
PR 合并指标
30 天内没有已合并 PR

环境准备

我们还没有检查这个项目的环境配置文件。先看它的 README,通用步骤见我们的新手贡献指南。

从这里开始

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

pyinvoke/invoke 的其他 Issue

查看 pyinvoke/invoke 的全部 Issue

相似的 Issue

更多 Python Issue

把新 issue 发到你的邮箱

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