[WIP] Keeping Git branches in sync with job-server workspaces

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

维护者通常 1 天内回复

还没有人认领这个 Issue。

评估

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

调研方向

先从此 issue 中的工作流和链接的技术支持交流开始,然后检查涵盖 Git 分支、job-server 工作区和研究人员工作流的文档。确定分支和工作区是否应保持同步,并记录针对主工作区和辅助工作区情况的建议。完成的标准是,最终形成的指导说明研究人员在请求进行修订后的分析后应采取哪些操作。

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

描述

In the Bristol-Cambridge-Oxford meeting on May 2, 2024 @venexia asked a question about keeping Git branches in sync with job-server workspaces. The question was prompted by an exchange with tech support.^1

We should recognize that it may not be desirable to keep Git branches in sync with job-server workspaces. Nevertheless, this issue captures the question and the exchange with tech support. Ultimately, the intention is to improve the documentation, by making recommendations to researchers.

In the following workflow, the primary branch is GitHub's default branch. It is often called main. The terms primary branch, primary workspace, secondary branch, and secondary workspace have no meaning beyond this issue. HEAD is Git-speak for "the current branch's latest commit".

  • Researcher creates repo from opensafely/research-template
  • Researcher commits to primary branch
  • Researcher creates primary workspace associated with primary branch
  • Researcher runs jobs in primary workspace
  • Primary workspace directories are created on L3 and L4 filesystems
  • Files are written to primary workspace directories
  • Researcher writes paper based on primary branch HEAD and files in primary workspace directories
  • Researcher submits paper 🎉

At this point, the paper is based on primary branch HEAD and files in primary workspace directories.

The paper is reviewed; further analysis is requested, which necessitates modifications to the dataset definition. The researcher doesn't want to overwrite files in primary workspace directories, because modifications to the dataset definition could result in a different dataset. 🙁

  • Researcher branches from primary branch, giving secondary branch
  • Researcher commits to secondary branch
  • Researcher creates secondary workspace associated with secondary branch
  • Researcher runs jobs in secondary workspace
  • Secondary workspace directories are created on L3 and L4 filesystems
  • Files are written to secondary workspace directories
  • Researcher updates paper based on secondary branch HEAD and files in secondary workspace directories
  • Researcher merges secondary branch into primary branch
  • Secondary branch is deleted (by researcher, by GitHub, etc.)
  • Researcher submits paper 🎉

At this point, the paper is based on primary branch HEAD and files in secondary workspace directories.

The paper is reviewed; further analysis is requested 🙁

  • Should the researcher commit to primary branch? Files in primary workspace directories are behind files in secondary workspace directories. The researcher would need to run jobs in primary workspace.

  • Should the researcher branch from primary branch, giving new secondary branch with same name as old secondary branch, and commit to new secondary branch? The researcher would not need to run jobs in secondary workspace.

主要语言
Python
星标
48
派生
10
平均合并
1 天 12 小时
30 天内合并 PR
11

环境准备

在 Codespaces 中打开

在浏览器里用你自己的 GitHub 账号启动这个项目的开发容器。

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

从这里开始

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

opensafely/documentation 的其他 Issue

查看 opensafely/documentation 的全部 Issue

相似的 Issue

更多 Python Issue

把新 issue 发到你的邮箱

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