Repository navigation
Remove the NotebookLM hooks and workflows: the sync is a stub and the gate checks a tracked constant #5957
Description
Owner decision 2026-10-04: remove NotebookLM from the git hooks and from CI ("do it").
What runs today, and what it does
The sync is a stub. contrib/backend/notebooklm/sync.py uploads placeholder text instead of the thing it is named after:
sync.py:334(handle_issue_comment): "In production, would fetch actual comment"sync.py:343(handle_pr_event): "In production, would fetch PR diff and comments"sync.py:55readssync_state.json; no such file exists in the tree.
CI swallows every failure of it.
.github/workflows/notebook-sync.yml:178-181:python3.10 sync.py "${SYNC_ARGS[@]}" || { echo "Sync completed with warnings"; exit 0; }.github/workflows/notebook-sync.yml:273:python3.10 contrib/backend/notebooklm/sync.py --activity || true.github/workflows/notebook-sync.yml:183-241(Update sync status as commit (best-effort),continue-on-error: true) tries to commit.trinity/notebook_sync_status.jsonto the default branch. The ruleset refuses that, and the step logs a warning and stays green.
Run 37183036041 (PR #5890) shows both: the sync step prints Syncing PR merge for #5890 and nothing after it. The next step logs Status commit skipped (409 Repository rule violations found ... Changes must be made through a pull request.). The job is green.
The last 100 notebook-sync.yml runs (2026-10-04 05:53Z to 07:51Z) are 84 success and 16 in progress, with 0 failures. A workflow that cannot fail tells nobody anything.
The gate checks a tracked constant.
.github/workflows/notebook-gate.yml:43-74and.githooks/pre-pushboth pass if.trinity/current_task/.notebook_idexists and matches^[a-zA-Z0-9]{8,}$.- That file is tracked in git. It holds
b83263109fb055dcand was last changed in ea15cd5 (conformance: promote gf256 -> strict SW-bitexact (last rung, 75/0/8) #1399). Every checkout carries it, so the gate passes for every PR and every push, whatever the change. - The last 100
notebook-gate.ymlruns are 89 success, 2 cancelled and 9 in progress, with 0 failures. - The fix the pre-push hook offers is
t27c bridge task start.bootstrap/src/bridge.rs:427-428makes "a fake notebook ID for now" of the formnb-<title>, and the hyphen fails the gate's own regex. - The pre-push hook also offers a bypass,
SKIP_NOTEBOOK_GATE=1.
The hooks start the stub on the developer's machine.
.githooks/pre-commit(the NotebookLM block aftertri hooks pre-commit) bumps a commit counter under the git common dir and, every third commit or when a.t27file is staged, startspython3.10 sync.pyin the background with>/dev/null 2>&1 || true..githooks/post-mergedoes the same after every merge.
Neither workflow is a required context. The ruleset (gh api repos/gHashTag/t27/rules/branches/master) requires validate, check-linked-issue and parse-ratchet.
Decision
Remove the NotebookLM part of the hooks and both workflows:
.githooks/pre-commit: remove the NotebookLM block; keeptri hooks pre-commit..githooks/pre-push: the whole file is the gate, so delete it..githooks/post-merge: the whole file is the sync, so delete it.- Delete
.github/workflows/notebook-sync.ymland.github/workflows/notebook-gate.yml. - Remove what only existed for these: the
SKIP_NOTEBOOK_GATEbypass, instructions that say a notebook must exist, and the CI test whose only subject is the branch-to-issue parser in the two hooks.
Out of scope, left for a follow-up: contrib/backend/notebooklm/, .trinity/current_task/.notebook_id and the local .trinity/notebook_commit_count. Once nothing calls them they are dead.
Stacked on #5951 (removes the NOW gate from the same hooks). Refs #5906.
Activity
Merge remove-now-gate into remove-notebooklm (Refs #5957)
review-speed plan: B27 done -- NOW and NotebookLM gates merged out (R…