Repository navigation
v3.48.0 — ### [3.48.0] — 2026-11-23
Minor by the version policy. Three gate changes make a shipped gate refuse more by default. Two are in fh-gate: a help or version flag is honoured only on its own (#1190), and under CI even a lone one exits 11 (#1191). Both close the same hole, where a file list that reads as a flag printed help, exited 0 and was read as a pass with no review. They close it in the GitHub Action and in CI systems that set CI; it stays open in CI systems that do not set CI and in local hooks or scripts (named in the second entry). The third is in destructive_pre_gate.sh: in block mode, which now includes auto as well as bypassPermissions, an override written into the command it is judging no longer opens the block, more shapes block, and the block text says to ask the operator (#1192); a follow-up closes three holes a security review found in it (#1195). See their BREAKING (gate): entries. fh-run and fh-goal stop pinning a codex model (#1189). The new shipped lanes are L8 and L9 in test_action_yml_lanes.sh, M1–M4 in test_fh_run_resolver_lanes.sh and test_fh_goal_change_detection_lanes.sh, and K1–K99 in test_destructive_pre_gate_lanes.sh. Items marked «not in the npm package» are in the repository checkout only.
Changed
- BREAKING (gate):
fh-gate(shipped), help and version flags with other arguments (#1190).- What changed:
-h,--help,-Vand--versionare honoured only as the sole argument. With any other argument,fh-gateexits 11 (argument error). In the GitHub Action (not in the npm package), exit 11 maps toARG_ERRORwithreviewed=false, and the step fails under the defaultfail-on. - Why: the Action always calls
fh-gate "$FILES" "$LEVEL" github-actionand maps exit 0 toverdict=PASS,reviewed=true. Afilesinput of-h,--help,-Vor--version(a file literally named so, or a list built from PR data) printed help, exited 0 and was reported as a reviewed PASS (3.47.0 release security review, MEDIUM-1). - What breaks: help or version with trailing arguments, including
FH_TARGET_FILES=x fh-gate -h quick, now exits 11.fh-gate -handfh-gate --versionalone behave as before outside CI (see the next entry). - Lanes: L8 in
scripts/test_action_yml_lanes.shruns the Action's run block against the realfh-gate.sh.
- What changed:
- BREAKING (gate):
fh-gate(shipped), a lone help or version flag under CI (#1191).- What changed: when the
CIenvironment variable is set to anything other than empty,0orfalse,fh-gate -h,--help,-Vand--versiongiven alone still print their text, then exit 11 (argument error) instead of 0. GitHub Actions, GitLab, CircleCI, Travis and Buildkite setCI. - Why: a plain CI step that runs
fh-gate "$FILES"withFILES=-hpasses the same arguments as a person typingfh-gate -h, so the rule above cannot see it: it printed help and exited 0, so the step passed and nothing was reviewed. - What breaks: a deliberate
fh-gate --versionor--helpin a CI step now fails that step. Workaround:CI= fh-gate --version. - Still open: CI systems that do not set
CI(Jenkins; Azure Pipelines setsTF_BUILDinstead) and local git hooks or scripts that callfh-gate "$FILES"with one argument. There,FILES=-hstill exits 0; check yourself that the file list does not start with-before callingfh-gate. - Outside CI, and with
CIempty,0orfalse, nothing changes. Lanes: L9 inscripts/test_action_yml_lanes.sh.
- What changed: when the
- BREAKING (gate):
destructive_pre_gate.sh(shipped), block mode no longer takes an override from the command it is judging (#1192).- What changed: block mode now also covers
permission_mode=auto, not onlybypassPermissions(explicitFH_DESTRUCTIVE_BLOCKstill wins either way). In block mode,# noqa: destructive-opis ignored, and four more shapes block:DESTRUCTIVE_OP_OK=set anywhere in the command,git push --no-verify,core.hooksPathchanged throughgit -corgit config, and remote deletes (git push --delete/-d/:ref/--mirror/--prune). The block text no longer names a way past: it tells the agent to stop and ask the operator, who runs the command from their own terminal. - Why: measured in a headless
bypassPermissionsrun (haiku, 3 of 3). The agent asked to force-push was blocked by this hook. It re-ran with# noqabecause the block text said to. Then pre-push blocked it, and it re-ran withDESTRUCTIVE_OP_OK=1because pre-push's text said to. The remote history was rewritten. The agent that wrote the command was also the one granting the exception. Inautomode the classifier allowed the same direct force push 6 of 6 times. - Who is affected:
bypassPermissionsandautosessions that legitimately force-push, delete remote branches or tags, runreset --hardand the other destructive rows, or set those overrides. Such a session now has to go through the operator. So does/install-wizard'sgit config core.hooksPath templates/.git-hooksstep when an agent runs it in those modes. Branch deletes done throughgh pr merge --delete-branchgo through the GitHub API and are not affected. A doc edit made through Bash that only mentionsDESTRUCTIVE_OP_OK=1also blocks in these modes, the same mention-as-data false positive the existing rows have. - What does not change: advisory mode (
default,acceptEdits,plan,dontAsk, orFH_DESTRUCTIVE_BLOCK=0) gets no new rows, and noqa still works. One advisory change comes from the follow-up below: a destructive command inside backticks now warns, as it already did inside$(...). The pre-push hook is unchanged: an operator's ownDESTRUCTIVE_OP_OK=1 git push …from their terminal works as before. - Also affected: with
FH_DESTRUCTIVE_BLOCK=1set in adefault-mode session,# noqano longer opens a block. That variable asks for blocking. - Follow-up (#1195), three holes found by a security review of the merged change and reproduced in
bypassPermissions(each passed with exit 0 before):git config core.hooksPath get(alsolist,--get,-l) set hooksPath to that word and switched off pre-push. The read exemption looked at the word after the key, which is the value. A read verb now counts only before the key, and a segment with--commentbefore the key is never a read. A value that starts with a backtick or a parenthesis (`printf /dev/null`,"(disabled)") now counts as a write too.git config get core.hooksPath,git config --get core.hooksPathand$(git config core.hooksPath)stay clean.- A remote delete with a push-option value of
-n(git push --delete origin x -o -n) was taken for a dry run. No regex here can tell an option value from a flag once quotes are stripped, so the dry-run exemption is now off whenever the statement has a push option (-o…,--pu…) or--: the call blocks. A plain--dry-run --deletestays clean. A push option whose value looks like:refalso blocks; that false positive was there before. - A destructive command inside backticks passed every row, while the same command inside
$(...)was caught. It existed before this change, and the new rows inherited it. Backticks are now treated like$(...), in both modes, and a dry-run in one substitution no longer clears a delete in the next. - Review stopped at two codex rounds, not converged: round 2 still found new shapes, both fixed.
- Still open: indirection (a script that holds the push and sets the variable inside), editing settings or the hook file to drop the hook, deleting refs through the GitHub API (
gh api -X DELETE …/git/refs/…),dontAskmode, and pushes from a shell the agent did not type into. A determined agent gets past any client-side check. The floor is server-side branch protection, as the pre-push header says. Moving pre-push's own override out of band is a separate, larger change, not in this one. Lanes: K1–K99, B4, B6 and B10 inscripts/test_destructive_pre_gate_lanes.sh.
- What changed: block mode now also covers
fh-runandfh-goal(shipped) no longer pass-m gpt-5.5to codex whenFH_MODELis unset or empty; codex picks its own default, asfh-gatehas done since #1186. Before, codex 0.164.0 refusedgpt-5.5for a ChatGPT-account login (HTTP 400).FH_MODEL=<id>still passes-m <id>, and the claude default (claude-sonnet-5-5) is unchanged (#1189).- After a successful unpinned codex run, each script prints one stderr line:
→ fh-run: codex default (not pinned, resolved <id>)(orfh-goal). The id is read from codex's own stderr banner above the firstuserline, and must be id-shaped, or the line saysunknown. - The
model=progress line and the prompt'sModel:line now readcodex default (not pinned)instead of a model id. A script that grepsmodel=gpt-5.5there stops matching. - API-key users who got
gpt-5.5before now get codex's default, so the model, cost and output can change. SetFH_MODELfor a reproducible model. Both points are indocs/codex-compat.mdand inknowledge/shared/harness-core/fh_integration_contract.md. fh-goalnever exported its default, so thefh-gatestep it runs was already unpinned. That is unchanged.
- After a successful unpinned codex run, each script prints one stderr line:
— CHANGELOG: plugins/fh-meta/CHANGELOG.md · npm: @chrono-meta/fh-gate@3.48.0