Require an open pull request before a second issue assignment
维护者通常 1 天内回复
还没有人认领这个 Issue。
评估
- 难度
- 4/5
- 预计耗时
- 3-5 天
- 新手友好度
- 68/100
- Issue 类型
- 功能
- 描述清晰度
- 描述清楚
- 活跃度
- 活跃
- 技术栈
- github, javascript
- 领域
- tooling
调研方向
Start in scripts/contributor-issue-comment.js at the existing limit check and formatAssignAtLimitMessage, then inspect getPullRequests and getLinkedIssues in scripts/utils.js. Run the relevant test-actions cases, including draft, closed, and non-closing links. Done means the assignment table and cooldown behavior remain correct, the waiting issue is named, and tests cover every acceptance criterion.
由索引模型根据 Issue 内容生成。
描述
Overview
A contributor with nothing assigned can take two issues at once and leave both untouched. The limit
counts slots, not progress. Issues are tagged against the team's capacity to review them, so an
assigned issue with no pull request holds a slot that was released deliberately.
Make the second slot conditional. A contributor holding one issue gets another only when that issue
already has an open pull request.
Complexity: Medium
Target branch: main
Context
The two issue limit already exists. scripts/contributor-issue-comment.js:176 declines a /assign
when totalSlots >= MAX_ASSIGNED_ISSUES, counting open assigned issues across COMMUNITY_REPOS
plus issues dropped inside the seven day cooldown. The decline posts a comment through
sendAssignReplyAndNotify and notifies Slack.
This change extends that check. It adds no automation, no registry entry, and no second comment.
The Change
Add a progress gate to the existing limit check, in this order:
| Assigned issues | Result |
|---|---|
| 0 | assign |
| 1, and that issue has an open pull request | assign |
| 1, with no open pull request | decline |
| 2 | decline, as today |
An issue counts as having an open pull request when one of the contributor's own open pull requests
links it with a closing keyword. A draft counts, because work has started. A closed pull request does
not count, because nothing is in flight.
Extend formatAssignAtLimitMessage rather than adding a message. It already lists the contributor's
current assignments. It needs to name the issue that is waiting for a pull request, and say that
unassigning it starts the seven day cooldown.
The gate applies to /assign only. A maintainer can still assign by hand, so exceptions stay
possible case by case.
Notes for the implementer
getPullRequests in scripts/utils.js already fetches a contributor's open pull requests across the
community repos. getLinkedIssues reads the closing links, but it takes the repo from
context.repo, so it needs the owner and repo passed in before it can check a pull request in
another repository.
Out of Scope
- Changing
MAX_ASSIGNED_ISSUESorASSIGN_COOLDOWN_DAYS. - Assignment by a maintainer.
- Any new comment, workflow, or automation.
Acceptance Criteria
- A contributor with no assigned issue is assigned as today.
- A contributor with one assigned issue that has an open pull request is assigned.
- A contributor with one assigned issue and no open pull request is declined.
- A draft pull request counts as an open one.
- A closed pull request does not count.
- A pull request that links the issue without a closing keyword does not count.
- A contributor with two assigned issues is declined, as today.
- The decline names the issue waiting for a pull request, and says that unassigning starts the
cooldown. - The existing cooldown behaviour is unchanged.
- Tests cover each row of the table.
Testing
Test in test-actions. See
testing the automations.
The cases need an account outside the organization.
- Comment
/assignon agood first issuewith nothing assigned. Expect assignment. - Comment
/assignon a second issue. Expect a decline naming the first issue. - Open a pull request that closes the first issue, then comment
/assignagain. Expect assignment. - Close that pull request, then try a third issue. Expect a decline.
References
- #103 adds
getLinkedIssues, and asks a contributor to link their issue when nothing is linked.
This gate depends on that link being there.
AI usage
I used Claude Code to check what the /assign flow already enforces and to draft this issue. I
decided the rule and the reading of what counts as progress.
- 主要语言
- JavaScript
- 星标
- 1
- 派生
- 7
- 平均合并
- 2 天 8 小时
- 30 天内合并 PR
- 10
环境准备
- 没有 Dockerfile 或 Docker Compose 文件
- 有 Pull Request 模板
- 阅读贡献指南
从这里开始
- 先读完整个 Issue,再读项目的贡献指南。
- 在 Issue 下留言说明你要接手 —— 这能避免两个人做同样的事。
- Fork 仓库,在一个分支上完成修改。
- 提交 Pull Request,并在描述里引用这个 Issue 编号。
learningequality/.github 的其他 Issue
-
难度 2/5 1-3 小时 新手友好度 75/100
learningequality/.github#112 ·
维护者通常 1 天内回复
-
难度 4/5 3-5 天 新手友好度 42/100
learningequality/.github#130 ·
维护者通常 1 天内回复
-
难度 4/5 3-5 天 新手友好度 45/100
learningequality/.github#129 ·
维护者通常 1 天内回复
-
难度 5/5 一周以上 新手友好度 24/100
learningequality/.github#128 ·
维护者通常 1 天内回复
-
难度 4/5 3-5 天 新手友好度 58/100
learningequality/.github#127 ·
维护者通常 1 天内回复
查看 learningequality/.github 的全部 Issue
相似的 Issue
-
enhancement
难度 2/5 1-3 小时 新手友好度 68/100
-
enhancement good first issue hacktoberfest help wanted
难度 2/5 1-3 小时 新手友好度 84/100
BinaryBaconLabs/todo-app#14 ·
-
难度 2/5 1-3 小时 新手友好度 78/100
liberation-data/drivine#428 · 1 条评论 ·
维护者通常 1 天内回复
-
难度 1/5 1 小时以内 新手友好度 78/100
-
难度 1/5 1 小时以内 新手友好度 88/100
celestiary/web#345 ·
维护者通常 1 天内回复