Skip to content

Commit cbd1f23

Browse files
🌱 Add triage-party for the Cluster API backlog (#10437)
* Add triage-party for the Cluster API backlog * Improve triage party make targets * Address comments * More comments
1 parent 3a3f65b commit cbd1f23

File tree

4 files changed

+684
-0
lines changed

4 files changed

+684
-0
lines changed

Makefile

Lines changed: 60 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -173,6 +173,12 @@ IMPORT_BOSS_VER := v0.28.1
173173
IMPORT_BOSS := $(abspath $(TOOLS_BIN_DIR)/$(IMPORT_BOSS_BIN))
174174
IMPORT_BOSS_PKG := k8s.io/code-generator/cmd/import-boss
175175

176+
TRIAGE_PARTY_IMAGE_NAME ?= extra/triage-party
177+
TRIAGE_PARTY_CONTROLLER_IMG ?= $(STAGING_REGISTRY)/$(TRIAGE_PARTY_IMAGE_NAME)
178+
TRIAGE_PARTY_DIR := hack/tools/triage
179+
TRIAGE_PARTY_TMP_DIR ?= $(TRIAGE_PARTY_DIR)/triage-party.tmp
180+
TRIAGE_PARTY_VERSION ?= v1.6.0
181+
176182
CONVERSION_VERIFIER_BIN := conversion-verifier
177183
CONVERSION_VERIFIER := $(abspath $(TOOLS_BIN_DIR)/$(CONVERSION_VERIFIER_BIN))
178184

@@ -1479,6 +1485,60 @@ $(GOVULNCHECK): # Build govulncheck.
14791485
$(IMPORT_BOSS): # Build import-boss
14801486
GOBIN=$(TOOLS_BIN_DIR) $(GO_INSTALL) $(IMPORT_BOSS_PKG) $(IMPORT_BOSS_BIN) $(IMPORT_BOSS_VER)
14811487

1488+
## --------------------------------------
1489+
## triage-party
1490+
## --------------------------------------
1491+
1492+
.PHONY: release-triage-party
1493+
release-triage-party: docker-build-triage-party docker-push-triage-party clean-triage-party
1494+
1495+
.PHONY: release-triage-party-local
1496+
release-triage-party-local: docker-build-triage-party clean-triage-party ## Release the triage party image for local use only
1497+
1498+
.PHONY: checkout-triage-party
1499+
checkout-triage-party:
1500+
@if [ -z "${TRIAGE_PARTY_VERSION}" ]; then echo "TRIAGE_PARTY_VERSION is not set"; exit 1; fi
1501+
@if [ -d "$(TRIAGE_PARTY_TMP_DIR)" ]; then \
1502+
echo "$(TRIAGE_PARTY_TMP_DIR) exists, skipping clone"; \
1503+
else \
1504+
git clone "https://github.com/google/triage-party.git" "$(TRIAGE_PARTY_TMP_DIR)"; \
1505+
cd "$(TRIAGE_PARTY_TMP_DIR)"; \
1506+
git checkout "$(TRIAGE_PARTY_VERSION)"; \
1507+
git apply "$(ROOT_DIR)/$(TRIAGE_PARTY_DIR)/triage-improvements.patch"; \
1508+
fi
1509+
@cd "$(ROOT_DIR)/$(TRIAGE_PARTY_TMP_DIR)"; \
1510+
if [ "$$(git describe --tag 2> /dev/null)" != "$(TRIAGE_PARTY_VERSION)" ]; then \
1511+
echo "ERROR: checked out version $$(git describe --tag 2> /dev/null) does not match expected version $(TRIAGE_PARTY_VERSION)"; \
1512+
exit 1; \
1513+
fi
1514+
1515+
.PHONY: docker-build-triage-party
1516+
docker-build-triage-party: checkout-triage-party
1517+
@if [ -z "${TRIAGE_PARTY_VERSION}" ]; then echo "TRIAGE_PARTY_VERSION is not set"; exit 1; fi
1518+
cd $(TRIAGE_PARTY_TMP_DIR) && \
1519+
docker buildx build --platform linux/amd64 -t $(TRIAGE_PARTY_CONTROLLER_IMG):$(TRIAGE_PARTY_VERSION) .
1520+
1521+
.PHONY: docker-push-triage-party
1522+
docker-push-triage-party:
1523+
@if [ -z "${TRIAGE_PARTY_VERSION}" ]; then echo "TRIAGE_PARTY_VERSION is not set"; exit 1; fi
1524+
docker push $(TRIAGE_PARTY_CONTROLLER_IMG):$(TRIAGE_PARTY_VERSION)
1525+
1526+
.PHONY: clean-triage-party
1527+
clean-triage-party:
1528+
rm -fr "$(TRIAGE_PARTY_TMP_DIR)"
1529+
1530+
.PHONY: triage-party
1531+
triage-party: ## Start a local instance of triage party
1532+
@if [ -z "${GITHUB_TOKEN}" ]; then echo "GITHUB_TOKEN is not set"; exit 1; fi
1533+
docker run --platform linux/amd64 --rm \
1534+
-e GITHUB_TOKEN \
1535+
-e "PERSIST_BACKEND=disk" \
1536+
-e "PERSIST_PATH=/app/.cache" \
1537+
-v "$(ROOT_DIR)/$(TRIAGE_PARTY_DIR)/.cache:/app/.cache" \
1538+
-v "$(ROOT_DIR)/$(TRIAGE_PARTY_DIR)/config.yaml:/app/config/config.yaml" \
1539+
-p 8080:8080 \
1540+
$(TRIAGE_PARTY_CONTROLLER_IMG):$(TRIAGE_PARTY_VERSION)
1541+
14821542
## --------------------------------------
14831543
## Helpers
14841544
## --------------------------------------

hack/tools/triage/.gitignore

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
triage-party.tmp/
2+
.cache/

hack/tools/triage/config.yaml

Lines changed: 287 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,287 @@
1+
settings:
2+
name: cluster-api
3+
min_similarity: 0.8
4+
repos:
5+
- https://github.com/kubernetes-sigs/cluster-api
6+
members:
7+
- chrischdi
8+
- enxebre
9+
- fabriziopandini
10+
- killianmuldoon
11+
- sbueringer
12+
- vincepri
13+
14+
collections:
15+
- id: initial-triage
16+
name: Initial Triage
17+
dedup: false
18+
description: >
19+
Check new issue and apply labels for kind, priority, area (optional).
20+
rules:
21+
- triage-needs-kind
22+
- triage-needs-priority
23+
24+
- id: triage-refinement
25+
name: Triage Refinement
26+
dedup: false
27+
description: >
28+
Work on issue to get them to an actionable state.
29+
When ready, apply triage/accepted and "help wanted" or "good first issue" label
30+
rules:
31+
- triage-stale-awaiting-more-evidence
32+
- triage-stale-kind-support
33+
- triage-updated
34+
- triage-again
35+
- triage-lifecycle-stale-or-rotten-priority-critical-urgent
36+
- triage-lifecycle-stale-or-rotten-priority-important-soon
37+
- triage-lifecycle-stale-or-rotten-priority-important-longterm
38+
- triage-lifecycle-frozen
39+
- triage-all
40+
41+
- id: actionable
42+
name: Actionable
43+
description: >
44+
Issues that can be worked on.
45+
dedup: false
46+
rules:
47+
- actionable-not-assigned-without-help-or-good-first-issue
48+
- actionable-updated
49+
- actionable-all
50+
51+
- id: fix-me
52+
name: Fix-me!
53+
description: >
54+
Ensure we are using the labels in a consistent way.
55+
dedup: false
56+
rules:
57+
- fixme-avoid-triage-needs-information
58+
- fixme-avoid-kind-design
59+
- fixme-kind-proposal-without-kind-feature
60+
- fixme-kind-support-with-other-kinds
61+
- fixme-triage-accepted-with-kind-support-or-priority-awaiting-more-evidence
62+
- fixme-help-or-good-first-issue-before-triage-accepted
63+
- fixme-lifecycle-frozen-with-priority-critical-urgent-priority-important-soon-priority-important-longterm
64+
65+
rules:
66+
# Phase: Initial triage
67+
68+
triage-needs-kind:
69+
# WHY?: kinds need to be assigned by maintainers, let's do it!
70+
name: "needs-kind"
71+
resolution: "Add a kind/ label: api-change, bug, cleanup, deprecation, documentation, failing-test, feature, flake, proposal, regression, release-blocking, support"
72+
type: issue
73+
filters:
74+
# TODO: Configure plugins so needs-kind label is applied + use it for this filter
75+
- label: "!kind/.*"
76+
77+
triage-needs-priority:
78+
# WHY?: kinds need to be assigned by maintainers, let's do it!
79+
name: "needs-priority"
80+
resolution: "Add a priority/ label: priority/critical-urgent > priority/important-soon > priority/important-longterm > priority/backlog > priority/awaiting-more-evidence"
81+
type: issue
82+
filters:
83+
# TODO: Configure plugins so needs-priority label is applied + use it for this filter
84+
- label: "!priority/.*"
85+
86+
# Phase: Triage finalization
87+
88+
triage-stale-awaiting-more-evidence:
89+
# WHY?: issue authors are supposed to provide answers timely when an issue is labeled priority/awaiting-more-evidence, otherwise /close
90+
name: "priority/awaiting-more-evidence not commented in the last 15 days"
91+
resolution: "Consider if to close with /close or to remove priority/awaiting-more-evidence label"
92+
type: issue
93+
filters:
94+
- label: "!triage/accepted"
95+
- label: "priority/awaiting-more-evidence"
96+
- commented: +15d
97+
98+
triage-stale-kind-support:
99+
# WHY?: support request are supposed to be quick back and forth between authors and maintainers, otherwise /close
100+
name: "Support request not commented in the last 15 days"
101+
resolution: "Consider if to close with /close or if to change kind"
102+
type: issue
103+
filters:
104+
- label: "!triage/accepted"
105+
- label: "kind/support"
106+
- commented: +15d
107+
108+
triage-updated:
109+
# WHY?: maintainers are supposed to keep up with issue discussions and help to move to actionable
110+
name: "Issues with updates in the last month"
111+
resolution: |
112+
Check if the issue is now actionable by applying /triage accepted, help in making progress, consider if to change priority or kind.
113+
Note: maintainers can't make everything actionable (so it is okay if this list does not go to 0).
114+
type: issue
115+
filters:
116+
- label: "!triage/accepted"
117+
- commented: -30d
118+
- tag: "!member-last"
119+
120+
triage-again:
121+
# WHY?: maintainers are supposed to re-assess triaged issues after some time (frequency depends on priority)
122+
name: "Issues back to triage"
123+
resolution: |
124+
Confirm that this issue is still relevant with /triage accepted or close this issue with /close.
125+
Note: this is a clear sign of project lacking contributors. At some point - might be after two back and forth -, we should give up and close.
126+
Note: it is be okay if this list does not go to 0, maintainers should not be forced to add an answer only for the sake of getting this list empty.
127+
type: issue
128+
filters:
129+
- label: "!triage/accepted"
130+
- un-triaged: +0d
131+
132+
triage-lifecycle-stale-or-rotten-priority-critical-urgent:
133+
# WHY?: issue with priority/critical-urgent do not get automatically closed, it is up to maintainers to take a look again
134+
name: "Issue with priority/critical-urgent, lifecycle/stale or rotten, and not commented in the last month"
135+
resolution: |
136+
Consider if bring this issue to the attention of the community, consider if to change priority with /priority important-soon, /priority important-longterm or /priority backlog, consider if to close with /close.
137+
Note: this is a clear sign of project lacking contributors. At some point - might be after two back and forth -, we should give up and close.
138+
Note: maintainers can't make everything actionable (so it is okay if this list does not go to 0).
139+
type: issue
140+
filters:
141+
- label: "!triage/accepted"
142+
- label: "priority/critical-urgent"
143+
- label: "lifecycle/(stale|rotten)"
144+
- commented: +30d
145+
146+
triage-lifecycle-stale-or-rotten-priority-important-soon:
147+
# WHY?: issue with priority/important-soon do not get automatically closed, it is up to maintainers to take a look again
148+
name: "Issue with priority/important-soon, lifecycle/stale or rotten, not commented in the last 2 month"
149+
resolution: |
150+
Consider if to change priority with /priority important-longterm or /priority backlog, consider if to close with /close.
151+
Note: this is a clear sign of project lacking contributors. At some point - might be after two back and forth -, we should give up and close.
152+
Note: maintainers can't make everything actionable (so it is okay if this list does not go to 0).
153+
type: issue
154+
filters:
155+
- label: "!triage/accepted"
156+
- label: "priority/important-soon"
157+
- label: "lifecycle/(stale|rotten)"
158+
- commented: +60d
159+
160+
triage-lifecycle-stale-or-rotten-priority-important-longterm:
161+
# WHY?: issue with priority/important-longterm do not get automatically closed, it is up to maintainers to take a look again
162+
name: "Issue with priority/important-longterm, lifecycle/stale or rotten, not commented in the last 6 months"
163+
resolution: |
164+
Consider if to change priority with /priority backlog, consider if to close with /close"
165+
Note: this is a clear sign of project lacking contributors. At some point - might be after two back and forth -, we should give up and close.
166+
Note: maintainers can't make everything actionable (so it is okay if this list does not go to 0).
167+
type: issue
168+
filters:
169+
- label: "!triage/accepted"
170+
- label: "priority/important-longterm"
171+
- label: "lifecycle/(stale|rotten)"
172+
- commented: +180d
173+
174+
triage-lifecycle-frozen:
175+
# WHY?: issue with lifecycle/frozen do not get automatically closed, it is up to maintainers to take a look again
176+
name: "Issue with lifecycle/frozen, not commented in the last 6 months"
177+
resolution: |
178+
Consider if to close with /close.
179+
Note: this is a clear sign of project lacking contributors. At some point - might be after two back and forth -, we should give up and close.
180+
Note: maintainers can't make everything actionable (so it is okay if this list does not go to 0).
181+
type: issue
182+
filters:
183+
- label: "!triage/accepted"
184+
- label: "lifecycle/frozen"
185+
- commented: +180d
186+
187+
triage-all:
188+
name: "All the issue in triage"
189+
resolution: |
190+
Check if the issue is now actionable by applying /triage accepted, help in making progress, consider if to change priority or kind.
191+
Note: This list is not intended to go to 0 items (it lists all).
192+
type: issue
193+
filters:
194+
- label: "!triage/accepted"
195+
196+
# Phase: Actionable
197+
198+
actionable-not-assigned-without-help-or-good-first-issue:
199+
# WHY?: issue actionable must be assigned to someone or seeking for help
200+
name: "Issues not assigned without help or good-first-issue"
201+
resolution: "Apply /help or /good-first-issue"
202+
type: issue
203+
filters:
204+
- label: "triage/accepted"
205+
- label: "!(help wanted|good first issue)"
206+
- tag: "!assigned"
207+
208+
actionable-updated:
209+
# WHY?: maintainers are supposed to keep up with issue discussions
210+
name: "Issues with updates in the last month"
211+
resolution: |
212+
Check updates
213+
Note: it is be okay if this list does not go to 0, maintainers should not be forced to add an answer only for the sake of getting this list empty.
214+
type: issue
215+
filters:
216+
- label: "triage/accepted"
217+
- commented: -30d
218+
- tag: "!member-last"
219+
220+
actionable-all:
221+
name: "All the actionable issues"
222+
resolution: |
223+
Note: This list is not intended to go to 0 items (it lists all).
224+
type: issue
225+
filters:
226+
- label: "triage/accepted"
227+
228+
# Fix-me
229+
# WHY?: Let's try to be diligent in using labels
230+
231+
fixme-avoid-triage-needs-information:
232+
name: "With triage/needs-information (let's not use this label)"
233+
resolution: "Remove triage/needs-information, use priority/awaiting-more-evidence instead"
234+
type: issue
235+
filters:
236+
- label: "triage/needs-information"
237+
238+
fixme-avoid-kind-design:
239+
name: "With kind/design (let's not use this label)"
240+
resolution: "remove kind/design, use kind/proposal instead"
241+
type: issue
242+
filters:
243+
- label: "kind/design"
244+
245+
fixme-kind-proposal-without-kind-feature:
246+
name: "With kind/proposal without kind/feature"
247+
resolution: "Add kind/feature (we usually write proposals for new features, so kind/proposal and kind/feature should go together)"
248+
type: issue
249+
filters:
250+
- label: "kind/proposal"
251+
- label: "!kind/feature"
252+
253+
fixme-kind-support-with-other-kinds:
254+
name: "With kind/support and also other kinds"
255+
resolution: "Remove incorrect kinds (kind/support should not be combined with other kinds)"
256+
type: issue
257+
filters:
258+
- label: "kind/support"
259+
- label: "kind/(feature|documentation|bug|flake|cleanup|design|proposal|deprecation|regression|api-change|failing-test|release-blocking)"
260+
261+
fixme-triage-accepted-with-kind-support-or-priority-awaiting-more-evidence:
262+
name: "With triage/accepted and kind/support or priority/awaiting-more-evidence"
263+
resolution: "Remove triage/accepted (triage/accepted should not be applied to issue with kind/support or priority/awaiting-more-evidence)"
264+
type: issue
265+
filters:
266+
- label: "triage/accepted"
267+
- label: "(kind/support|priority/awaiting-more-evidence)"
268+
269+
fixme-help-or-good-first-issue-before-triage-accepted:
270+
name: "With help or good-first-issue applied before triage/accepted"
271+
resolution: "help or good-first-issue should not be applied before triage/accepted"
272+
type: issue
273+
filters:
274+
- label: "(help wanted|good first issue)"
275+
- label: "!triage/accepted"
276+
- tag: "!untriaged"
277+
278+
fixme-lifecycle-frozen-with-priority-critical-urgent-priority-important-soon-priority-important-longterm:
279+
name: "With lifecycle/frozen and one of priority/critical-urgent, priority/important-soon or priority/important-longterm"
280+
resolution: "Remove lifecycle/frozen (priority/critical-urgent, priority/important-soon or priority/important-longterm are not subject to lifecycle events)"
281+
type: issue
282+
filters:
283+
- label: "lifecycle/frozen"
284+
- label: "priority/(critical-urgent|important-soon|important-longterm)"
285+
286+
# TODO: add more checks about invalid combinations of labels
287+
# - ...

0 commit comments

Comments
 (0)