Files
ISEP/labels.yaml
claude-code f3a41fba0e 下游做完時頂層跟著關(inkstone/ISEP#92)
票上的病:「開在頂層的票,下游做完了卻沒人回來關⋯⋯頂層票會永遠掛著,
而 leo 是看頂層的。」缺的三格是 journey 標籤、雙向連結的強制、完工回寫。

不重造既有的(票上明列):`ticket where` 戳記+側門閘(查票防重複)、
`comment-carries-task-guard`(留言藏任務)、Gitea 原生 issue dependency
(跨 repo 關聯的載體)——這一版全部長在它們上面。

四格,判準全部是機械事實(相依邊在不在、state 是什麼),沒有一格在猜文字:

① 雙向連結(驗收 1):`subtask`/新別名 `handoff` 一個動作同時掛原生相依
   + 在頂層票的時間軸貼一則指回下游的留言。相依邊只長在側欄,
   時間軸上什麼都沒有,跨 repo 時尤其看不出來。

② 完工回寫(驗收 2,最痛的那格):`ticket close` 關完子票立刻問 `/blocks`
   (誰在等我),對每張還開著的頂層票貼回寫留言;下游全關的那一張再
   指派回總管+改 s/review。**不自動關母票**——關票要有交付物、要有人看過,
   默默關掉跟默默留著是同一個病的兩面。

③ journey 標籤:`--journey <名>` 把 `j/<名>` 同時貼在母子兩端(只貼一端就
   聚不起來)。標籤不存在就擋下並指回 labels.yaml——要求標籤在場,
   不是猜哪些名字合法。labels.yaml 的 `j/` 段刻意留空:旅程怎麼切、叫什麼
   名字是方向題,不由工具代決。

④ 撈得出來(驗收 3、4):新動詞 `ticket loose` 掃 org 的 open 票,撈
   「有下游相依、下游全關、自己還開著」的頂層票。這是 ② 的補網——
   關票的側門(直接 PATCH state=closed)是刻意放行的,漏掉的由這張網撈回來。
   不是輪詢,掛在開場/收工對帳跑一次。

實跑(2026-08-28,唯讀,沒動任何票):245 張 open 票裡 17 張有下游相依,
其中 2 張是「下游都關了、自己還開著」——inkstone/arcrun-rag#136(已 s/review
且指派給 claude-code,正在被處理)與 inkstone/Arcrun#100(沒標籤、沒指派,
就是票上講的那種「永遠掛著」)。

測試:scripts/test-ticket-handoff-writeback.sh,49 條全綠,全程離線
(會打 API 的兩段把 api() 換成錄音機,不開票不關票不留測試票)。
回歸:A13 17/17、A4 24/24、A12 11/11 皆綠。
文件:docs/TESTING.md 新增 A16。

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_016ZBu4Sa1cGntKFRBYNZ6xs
2026-08-28 00:31:35 +00:00

134 lines
5.2 KiB
YAML
Raw Permalink Blame History

This file contains ambiguous Unicode characters
This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.
# ISEP labels.yaml — 全 inkstone org 的標籤唯一真相源
# 規約:改標籤=改本檔 → PR → release → 跑 scripts/gitea-labels-sync.sh
# scope 帶「/」且 exclusive:true 者,同票至多一個(Gitea 平台保證,非法狀態不可表示)
labels:
# ── 狀態機(exclusive,同票只能有一個)─────────────────
- name: "s/triage"
color: "d4c5f9"
exclusive: true
description: "新進來的,還沒驗傷——還沒決定要不要做"
- name: "s/backlog"
color: "c2e0c6"
exclusive: true
description: "驗過了、確定要做,但還沒排進任何 sprint"
- name: "s/todo"
color: "ededed"
exclusive: true
description: "已排進 milestone,等人領票"
- name: "s/doing"
color: "0e8a16"
exclusive: true
description: "進行中——已 self-assign,現在有人在做"
- name: "s/review"
color: "1d76db"
exclusive: true
description: "PR 已開(含 closes #n),等總管 review 並 merge"
- name: "s/stage"
color: "5319e7"
exclusive: true
description: "已部署 stage,等 leo 實際驗收"
- name: "s/pending"
color: "fbca04"
exclusive: true
description: "卡住——等外部/等依賴,不是沒人做"
# ── 關閉分類(exclusive,關票必掛恰好一個)──────────────
- name: "close/merged"
color: "0e8a16"
exclusive: true
description: "PR merge 自動關(正常路徑)"
- name: "close/human-exec"
color: "b60205"
exclusive: true
description: "人執票完成,由人手動關"
- name: "close/duplicate"
color: "cfd3d7"
exclusive: true
description: "重複——關新的、留舊的,並指向舊票"
- name: "close/wontfix"
color: "6c757d"
exclusive: true
description: "討論後決定不做(只有 leo 可下此判斷)"
- name: "close/transferred"
color: "cfd3d7"
exclusive: true
description: "走錯棚,已在正確的 repo 重開"
- name: "close/split"
color: "cfd3d7"
exclusive: true
description: "太大,已拆成數張子票"
- name: "close/stale"
color: "cfd3d7"
exclusive: true
description: "逾期無資訊,自動關閉"
# ── 人的介入(正交維度,可疊在任何 s/* 上,故不 exclusive)──
- name: "Human"
color: "b60205"
exclusive: false
description: "👤 這件事需要 leo 親手批示/動手(花錢・不可逆・品味方向・物理動作)。與 s/* 正交"
- name: "human/exec"
color: "e99695"
exclusive: false
description: "👤 這張票的『執行者』是人(GUI-only/實體權限/法定簽署),不是審核。交付物是環境狀態改變,不是 PR"
# ── 優先序(exclusive)───────────────────────────────
- name: "p/high"
color: "b60205"
exclusive: true
description: "高——擋住交付或有時間壓力"
- name: "p/low"
color: "bfd4f2"
exclusive: true
description: "低——想做,但晚一點沒關係"
# ── 種類(exclusive)────────────────────────────────
- name: "type/bug"
color: "d73a4a"
exclusive: true
description: "壞掉的東西"
- name: "type/feature"
color: "a2eeef"
exclusive: true
description: "新能力"
- name: "type/governance"
color: "5319e7"
exclusive: true
description: "規範、流程、閘本身"
- name: "type/chore"
color: "fef2c0"
exclusive: true
description: "雜務、整理、不改行為"
# ── 使用者旅程(正交,`j/` scope)──────────────────
#
# inkstone/ISEP#92:「這件事服務哪個使用者旅程,沒有記錄⋯⋯後面要把相關的票
# 聚成一包時,只能靠人重新讀一遍每張票在講什麼。」
#
# `ticket subtask/handoff --journey <名>` 會把 `j/<名>` **同時貼在母子兩端**
# (只貼一端就聚不起來)。標籤不存在時它會擋下來並指回本檔——
# **「要求標籤在場」,不是「猜哪些名字合法」**。
#
# 🔴 這裡刻意是空的。旅程怎麼切、叫什麼名字,是方向題(四題公式第 4 題),
# 不該由工具或 subagent 代決;隨手造名字會讓同一條旅程長出三個拼法。
# 要新增一條就照這個形狀加一筆,然後跑 scripts/gitea-labels-sync.sh
#
# - name: "j/收件匣"
# color: "fbca04"
# exclusive: false
# description: "🧭 旅程:<一句話講這條旅程的頭和尾>"
#
# (票上明講「對不上就不貼,不硬湊」——沒有對應旅程的票就不要加 --journey。)
# ── 結構(正交)──────────────────────────────────
- name: "hub"
color: "0052cc"
exclusive: false
description: "Tracking issue——聚合一批 leaf 的 scope 容器,本身不掛 milestone、不對應 PR"
# 舊標籤:不刪(刪掉會從既有票上被摘除,歷史就斷了),改標記封存
archive:
- name: "duplicate"
reason: "由 close/duplicate 取代"