-
Notifications
You must be signed in to change notification settings - Fork 156
Allow refactor label to meet CI requirement
#2573
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
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -5,6 +5,7 @@ changelog: | |
| labels: | ||
| - dependencies | ||
| - chore | ||
| - refactor | ||
| authors: | ||
| - dependabot | ||
| categories: | ||
|
|
||
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -8,6 +8,7 @@ REQUIRED_LABELS = [ | |
| "bugfix", | ||
| "chore", | ||
| "enhancement", | ||
| "refactor", | ||
| "ignore-for-release", | ||
| "security", | ||
| "sorbet", | ||
|
|
@@ -26,7 +27,13 @@ labels = JSON.parse(arg)["labels"].map { |label| label["name"] } | |
| matching_labels = labels & REQUIRED_LABELS | ||
|
|
||
| if matching_labels.empty? | ||
| warn("PR is missing at least one of the following labels: #{REQUIRED_LABELS.join(", ")}") | ||
| warn <<~MSG | ||
|
Contributor
Author
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. This error will always be triggered on community contributed PRs, whose authors wouldn't have the access level necessary to label it themselves. We talked about this with the team a while ago, and didn't have a good solution. For now, let's at least give more clear instruction.
Contributor
Author
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. |
||
| Tapioca has an automated release process which generates the release notes based on PRs labels. | ||
| (See https://github.com/Shopify/tapioca/blob/main/.github/release.yml) | ||
|
|
||
| Please ask a Shopify employee to label your PR with at least one of the following labels: | ||
| #{REQUIRED_LABELS.map { |label| " - #{label}" }.join("\n")} | ||
| MSG | ||
| exit(1) | ||
| end | ||
|
|
||
|
|
||
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.
This on its own isn't enough, we need to also classify the tag to feed into one of the release categories here: https://github.com/Shopify/tapioca/blob/main/.github/release.yml#L10-L23
Actually, maybe, instead of manually maintaining this list, we should just check against the union of labels for all the categories
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.
We could continue using
chorefor this as it doesn't bring much value for end usersThere 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 can also see us adding
refactorto theexcludelist.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 like adding it to the exclude list.