New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
RFC issue generation #141
Closed
Closed
RFC issue generation #141
Changes from all commits
Commits
Show all changes
7 commits
Select commit
Hold shift + click to select a range
62a9efc
RFC issue generation
jromero e5d1ed3
alternative pros/cons + definitions
jromero 0e79c22
Update 0000-rfc-issue-generation.md
jromero dcb089d
Remove pending TODO
jromero 0c6a911
Replace primary solution with alternative
jromero 98ec422
Provide a simplified "what it is" description
jromero 9ca24d8
Update text/0000-rfc-issue-generation.md
jromero File filter
Filter by extension
Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,196 @@ | ||
# Meta | ||
[meta]: #meta | ||
- Name: RFC Issue Generation | ||
- Start Date: 2020-03-03 | ||
- Author(s): @jromero | ||
- RFC Pull Request: (leave blank) | ||
- CNB Pull Request: (leave blank) | ||
- CNB Issue: (leave blank) | ||
- Supersedes: "N/A" | ||
|
||
# Summary | ||
[summary]: #summary | ||
|
||
This RFC proposes an automated mechanism for generating issues for the appropriete repositories from RFCs during the RFC process. | ||
|
||
# Definitions | ||
[definitions]: #definitions | ||
|
||
- _Bot_ - The GitHub account used to run automated actions. | ||
- [RFC](https://github.com/buildpacks/rfcs/blob/rfc-issue-generation/text/0004-rfc-process.md#what-it-is) - The formal process of recording and collecting input for proposed changes. | ||
- [Repositories](https://github.com/buildpacks) - The code repositories maintained by the Cloud Native Buildpacks project. | ||
- [Maintainers](https://github.com/buildpacks/community/blob/main/GOVERNANCE.md#maintainers) - Individuals with elevated responsibilities regarding the day-to-day operations of any given sub-team. | ||
- Queued Issues - A list of issues to be created when the RFC is merged. | ||
|
||
# Motivation | ||
[motivation]: #motivation | ||
|
||
The current RFC process [requires labels for individual sub-teams of relevance to be added](https://github.com/buildpacks/rfcs/blob/main/text/0059-label-rfcs.md). | ||
Later, after the RFC has been approved, it requires maintainers of affected sub-teams to create issues on their respective repositories. | ||
This typically happens days, weeks, if not months after the maintainers might have reviewed the RFC. | ||
In addition, it usually requires the person merging the RFC to hunt down (or ping) any maintainers for sub-teams that haven't created relevant issues. | ||
|
||
The goal of this RFC is to minimize the overhead of creating issues for maintainers and the individual merging the RFCs by incorporating the processes into the review process as opposed to the merge process. | ||
|
||
# What it is | ||
[what-it-is]: #what-it-is | ||
|
||
This solution is comprised of a _bot_ (a faux GitHub account) and updates to the [`merge-rfc.sh`](https://github.com/buildpacks/rfcs/blob/main/merge-rfc.sh) script. The bot, likely to be implemented via GitHub Actions, monitors pull requests in `buildpacks/rfcs` for comments while maintaining a list of _queued issues_. `merge-rfc.sh` would be updated to parse the list of queued issues and create those issues in their respective repositories. | ||
|
||
# How it Works | ||
[how-it-works]: #how-it-works | ||
|
||
When a pull request is created on `buildpacks/rfcs` the bot would post a comment with the following content: | ||
|
||
> | ||
> Maintainers, | ||
> | ||
> As you review this RFC please queue up issues to be created using the following commands: | ||
> | ||
> - `/queue-issue <repo> "<title>" [labels]...` | ||
> - `/unqueue-issue <uid>` | ||
> | ||
> **Queued Issues** | ||
> | ||
> _(none yet)_ | ||
> | ||
|
||
The bot will monitor comments to pull requests. It will parse the contents in search for instructions `/queue-issue` or `/unqueue-issue`. If found, it would take the approprite action by updating the initial comment posted with a list of queued issues. In the case of an addition a short UID would be generated. | ||
|
||
#### Example Addition | ||
|
||
Addition Comment: | ||
|
||
``` | ||
/queue-issue buildpacks/rfcs "Create issues from RFCs (merge-rfc.sh)" [label1][label2] | ||
``` | ||
|
||
Updated Bot Comment: | ||
|
||
> | ||
> Maintainers, | ||
> | ||
> As you review this RFC please queue up issues to be created using the following commands: | ||
> | ||
> - `/queue-issue <repo> "<title>" [labels]...` | ||
> - `/unqueue-issue <uid>` | ||
> | ||
> **Queued Issues** | ||
> | ||
> - Xoq7ID - buildpacks/rfcs "Create issues from RFCs (merge-rfc.sh)" [label1][label2] | ||
> | ||
|
||
|
||
#### Example Removal | ||
|
||
Remove Comment: | ||
|
||
``` | ||
/unqueue-issue Xoq7ID | ||
``` | ||
|
||
Updated Bot Comment: | ||
|
||
> | ||
> Maintainers, | ||
> | ||
> As you review this RFC please queue up issues to be created using the following commands: | ||
> | ||
> - `/queue-issue <repo> "<title>" [labels]...` | ||
> - `/unqueue-issue <uid>` | ||
> | ||
> **Queued Issues** | ||
> | ||
> _(none)_ | ||
> | ||
|
||
Once the RFC is merged via the [`merge-rfc.sh`](https://github.com/buildpacks/rfcs/blob/main/merge-rfc.sh) script, the script could detect issues by looking through the top comment from the _bot_ and creating any queued issues. Some additions that the script may do but subject to change: | ||
|
||
- Prepend `[RFC #<number>]` to issue titles. | ||
- Append link to Pull Request to issue description. | ||
- Add additional labels. | ||
|
||
# Drawbacks | ||
[drawbacks]: #drawbacks | ||
|
||
The following are pros and cons as compared to alternative solutions. | ||
|
||
##### Pros | ||
|
||
- No need for maintainers to suggest edits and ensure author adds issues. | ||
|
||
##### Cons | ||
|
||
- Added complexity of implementing and maintaining a bot. | ||
|
||
# Alternatives | ||
[alternatives]: #alternatives | ||
|
||
|
||
### Add markdown to RFC template | ||
|
||
The proposal would be to add the following information to the end of the RFC template: | ||
|
||
```markdown | ||
# Issues to Create | ||
|
||
<!-- THIS SECTION IS INTENDED TO BE FILLED BY MAINTAINERS DURING THE RFC PROCESS. --> | ||
|
||
Issues listed below will be created once this RFC is approved and merged: | ||
|
||
<!-- | ||
FORMAT: - <repo>: <title> [labels]... | ||
EXAMPLES: | ||
- buildpacks/lifecycle: Implement something | ||
- buildpacks/pack: Support this thing [good first issue][status/triage] | ||
--> | ||
``` | ||
|
||
During the review process, as maintainers review the RFC they can [suggest changes](https://docs.github.com/en/github/collaborating-with-issues-and-pull-requests/commenting-on-a-pull-request#adding-line-comments-to-a-pull-request) to this section by adding a line in the following format: | ||
|
||
``` | ||
- <repo>: <title> [labels]... | ||
``` | ||
|
||
Once, the RFC is approved and ready to merge the [`merge-rfc.sh`](https://github.com/buildpacks/rfcs/blob/main/merge-rfc.sh) can parse the list in this section and create the respective issues. | ||
|
||
|
||
##### Pros | ||
|
||
- Minimal additional implementation complexity. | ||
|
||
##### Cons | ||
|
||
- The RFC author is required to accept the suggested changes, preferably with proper DCO signatures. This would be adding a bit of toil on the authors behalf. | ||
|
||
### Keep management of issues seperate | ||
|
||
Find an alternative location to store pending issues to create. | ||
|
||
Examples: | ||
|
||
- Google Sheets | ||
- Seperate Repository | ||
|
||
##### Pros | ||
|
||
- No need for maintainers to suggest edits and ensure author adds issues. | ||
|
||
##### Cons | ||
|
||
- Location of issue "management" is distant from RFC making it hard to trace or more tedious to work with. | ||
|
||
# Prior Art | ||
[prior-art]: #prior-art | ||
|
||
- [prow](https://github.com/kubernetes/test-infra/tree/master/prow) - A heavy-weight k8s automation system used largely by the k8s ecosystem to automate certain aspects of the review process using "chat-ops" (`/test`, `/approve`, `/assign` comments). | ||
|
||
# Unresolved Questions | ||
[unresolved-questions]: #unresolved-questions | ||
|
||
- Should these operations be restricted to users that are in `@buildpacks/*-maintainer` groups? Maybe expand it to `@buildpacks/*-contributors`? | ||
|
||
# Spec. Changes | ||
[spec-changes]: #spec-changes | ||
|
||
None |
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I assume this could be done via a GitHub action on PR merges?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
At a later point in time or via separate initiative, yes.