Skip to content

docs(ci): 收回「訊號只是換個信使」—— gh_events 對 dependabot 分支靜音 - #76

Open
jonatw wants to merge 1 commit into
mainfrom
docs/signal-not-lost-is-false
Open

docs(ci): 收回「訊號只是換個信使」—— gh_events 對 dependabot 分支靜音#76
jonatw wants to merge 1 commit into
mainfrom
docs/signal-not-lost-is-false

Conversation

@jonatw

@jonatw jonatw commented Aug 4, 2026

Copy link
Copy Markdown
Owner

掃 dependabot 相關 issue 時撞到 openab-infra#359,它證明 #71 留下的一句註解在最要緊的地方是錯的。

錯在哪

現行註解:

The signal is not lost -- the CI workflow itself still goes red and still fires its event; only the messenger changes.

後半句誤導。GitHub 層確實發了 workflow_run 事件,但艦隊通報層丟掉:

# openab-infra lambda/gh_events/handler.py:391  (main, 未修)
if wf.get("conclusion") != "failure" or wf.get("head_branch") != "main":
    return None

dependabot PR 在 dependabot/* 上 ⇒ 落在 filter 外側,一則都不會進 Discord

#359 的實據:本 fleet 有 3 筆 conclusion=failure 發生在 dependabot 分支(2026-07-23、07-30 ×2),零推播

⇒ 這句話讓讀者以為「有人會發現」,而實際上沒有 —— 正是 #71 那輪在清的那種假保證,我自己又寫了一個。

順帶:這反過來替「拿掉 poll」背書

#359 第 5 點:poll 版的紅 run 同樣掛在 dependabot/* 上、同樣被同一條 filter 丟掉。poll 與 --auto 在推播上完全等價,poll 只是多燒 30 分鐘 runner。

⇒ 移除 poll 沒有弄丟一個本來存在的訊號。老鷹在 #71 的 F3、以及我照著寫的註解,都高估了 poll 給的東西。這次一併寫進去。

改了什麼

純註解,零行為變更:

  • 收回「只是換個信使」,寫明今天沒有任何主動通報,附 #359 / PR 361 當出處與時間戳
  • 記下 poll 與 --auto 在推播上等價
  • 指向真正的解(排程 watchdog)

PR 361 一 merge 這段就會過期(那時通報會恢復)—— 所以我把「still open as of 2026-08-04」寫進註解,讓它自己標示保鮮期。

actionlint clean。

#71 留下的註解寫「CI 照樣紅、照樣觸發事件,只是換個信使」。掃 dependabot
issue 時撞到 openab-infra#359:GitHub 層事件有發,但艦隊通報層丟掉 ——
handler.py:391 的 workflow_run 失敗只在 head_branch == "main" 才推播,
dependabot PR 在 dependabot/* 上 ⇒ 零推播。#359 實據:本 fleet 三筆真失敗
在 dependabot 分支(07-23、07-30 x2),沒有一則進 Discord。

那句話讓讀者以為有人會發現,實際沒有 —— 正是 #71 那輪在清的假保證。

順帶記下 #359 第 5 點:poll 版的紅 run 同樣在 dependabot/* 上、同樣被同一條
filter 丟掉 ⇒ poll 與 --auto 在推播上等價,移除 poll 沒有弄丟本來存在的訊號。
這比原註解與 #71 F3 的說法都精確。

註解裡標了「PR 361 still open as of 2026-08-04」,讓它自己標示保鮮期。

無行為變更。actionlint clean。

Refs #74, openab-infra#359
Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
@gemini-code-assist

Copy link
Copy Markdown

Note

Gemini is unable to generate a review for this pull request due to the file types involved not being currently supported.

@cloudflare-workers-and-pages

Copy link
Copy Markdown

Deploying pdf-processor with  Cloudflare Pages  Cloudflare Pages

Latest commit: e969ec4
Status: ✅  Deploy successful!
Preview URL: https://c3326bef.pdf-processor-41c.pages.dev
Branch Preview URL: https://docs-signal-not-lost-is-fals.pdf-processor-41c.pages.dev

View logs

@jonatw-eagle jonatw-eagle Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

request-changes:方向對、寫得也好,但這段文字的前提在你寫完 3 小時後被 merge 掉了

先講清楚這不是你做錯:你 07:35Z 推這版時每一句都是對的。openab-infra PR #361 在 2026-08-04T10:42:10Z merge,把 head_branch == "main" 那個 filter 放寬了 —— 於是這段註解最重要的那句「today NOTHING actively tells anyone」現在是假的。docs 的價值全在準確度,這種註解會被後人當事實引用(!! Do NOT write that off... 的語氣更會),所以擋一下。

已驗事實(我自己跑的,不是讀自述)

# 事實 佐證
F1 main 上的 filter 已經放寬 lambda/gh_events/handler.py:397-399head = wf.get("head_branch") or "" / if not (head == "main" or head.startswith("dependabot/")): return None
F2 而且已經上線,不只是 merge 進 main cdk run(merge commit 6c927ba2)2026-08-04T10:42:12Z success;Lambda openab-gh-events LastModified = 2026-08-04T10:43:39Z(唯讀 role 讀得到)
F3 這份一模一樣的文字已經進了 pdf-watermark-removemain 該 repo PR #26,你 08:12:43Z merge 的 —— 早於 #361 merge 2.5 小時 ⇒ 那邊現在也帶著同一段過期敘述。我實查該 repo main 的 workflow 檔,NOTHING actively tells / still open as of / head_branch == "main" 三段字串都在

三處要改

① 「So today NOTHING actively tells anyone」→ 已不成立
現在 dependabot/* 分支上的 CI 紅推播。殘留的盲區小得多、而且是另一件事:dependabot-automerge 這支 workflow 自己的紅被 handler.py:406 的 exclusion 吃掉(追蹤在 openab-infra#362 N1)—— 但這支改用 --auto 之後基本不會紅,所以它不是主要缺口。

② 「openab-infra#359(3 real failures ... 0 pushed)」→ 3 是被推翻的數字
我在 #359 的 2026-08-04T05:36 留言 §1 就當場更正過(重掃 /actions/runs?status=failure&per_page=100):全艦隊實際是 17 筆pdf-processor 9、lido_genius 8、pdf-watermark-remove 0),其中只有 2 筆是 automerge 自己空轉、15 筆是真訊號0 pushed 那半句當時是對的。
⇒ 引用時請指向那則留言,不要指向 #359 的 body(body 那張表就是被更正掉的那版)。

③ 「tracked in #74」→ #74 已 close
jonatw 2026-08-04 拍板做一支共用的 watchdog,三張 per-repo 票(pdf-processor#74pdf-watermark-remove#25lido_genius#138)都 close 並指向 openab-infra#365。指著 #74 會把後人送到一張關掉的票。#75(close-stale-prs 在第 28 天抹掉訊號)仍然開著、仍然有效,那句留著。

建議改寫(可直接取代 !! Do NOT write that offtracked in #74 那整段)

# !! Do NOT write that off as "the signal just moves to the test run". The first
# version of this comment said exactly that, and it was wrong for months: gh_events
# used to push a `workflow_run` failure only when `head_branch == "main"`, and a
# Dependabot PR lives on `dependabot/*`, so nothing actively told anyone.
#
# Fixed 2026-08-04: openab-infra PR 361 widened the filter to `main` OR
# `dependabot/*` (merged 10:42Z, deployed 10:43Z). A red required check on a
# Dependabot PR now does reach Discord. Evidence for how much was being dropped:
# openab-infra#359, comment 2026-08-04T05:36Z -- 17 failures on dependabot branches
# fleet-wide, 15 of them real signal, 0 pushed before the fix.
#
# Residual blind spot, much smaller: gh_events still drops failures of the
# `dependabot-automerge` workflow *itself* (deliberate -- its reds were mostly merge
# races). Tracked in openab-infra#362. With `--auto` this workflow barely runs long
# enough to fail, so this is a corner, not the hole the paragraph above described.
#
# Still worth knowing: the poll loop this replaced was NOT a safety net either -- its
# red run was also on a `dependabot/*` branch and was dropped by the same filter.
# Poll and `--auto` were equivalent for notification; the poll just also burned
# 30 runner-minutes per PR. Removing it did not cost a signal that existed.
#
# A scheduled watchdog that sweeps open Dependabot PRs is still wanted (it catches
# "stuck for other reasons", not just "check went red") -- tracked in
# openab-infra#365 (one shared watchdog, supersedes the per-repo #74), and #75 for
# how close-stale-prs erases the signal at day 28.

(措辭隨你,我要的是那三個事實對。)

這支 PR 之外、別掉的一件事

pdf-watermark-removemain 已經帶著同一段過期文字(F3)。我已開該 repo 的 issue 追蹤,needs-human —— 因為改 .github/workflows/* 需要 workflows:writeeagle App 沒有、執行手也沒有,這一刀只有你或 main-Claude 按得動。

我沒驗的

  • 沒有實際看到一則 dependabot 分支的紅 run 真的推進 Discord —— 那需要等下一顆 bump 紅掉(AGENT_BOTS + loop guard 雙擋,我造不出測試事件)。上面 F1/F2 只證明「程式碼與部署都到位」,不是「線上跑通過」。這條追蹤在 openab-infra#359 的關單留言。
  • checks=SUCCESSmergeState=BLOCKED(缺 review)。merge 鍵不歸我:這支動 .github/workflows/*,eagle App 無 workflows:write

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant