registration_problems rejects any SessionEnd group carrying a matcher key at all, so an empty matcher and * are both reported:
the SessionEnd sweep is registered under a matcher (''), so it runs on that exit reason alone
By the matcher semantics the same file documents one function away, in matcher_sees_bash, "An absent or empty matcher runs on every tool and * is the all-tools spelling", such a group fires on every exit reason. The sweep does run, and the reported reason is the opposite of what happens.
matcher_sees_bash was added in #1632 for exactly this class on the PreToolUse side, where requiring the exact string reported three working shapes as broken, and the SessionEnd side was left testing "matcher" in group. An empty matcher is the shape runs_hook's own docstring cites as realistic, written by hand or through the /hooks UI.
The fix is the SessionEnd counterpart of matcher_sees_bash: a matcher that is absent, empty or * covers every exit reason and is not a defect, and only a matcher naming specific reasons is. Found by a local strict review pass on #1632.
registration_problemsrejects any SessionEnd group carrying amatcherkey at all, so an empty matcher and*are both reported:By the matcher semantics the same file documents one function away, in
matcher_sees_bash, "An absent or empty matcher runs on every tool and*is the all-tools spelling", such a group fires on every exit reason. The sweep does run, and the reported reason is the opposite of what happens.matcher_sees_bashwas added in #1632 for exactly this class on the PreToolUse side, where requiring the exact string reported three working shapes as broken, and the SessionEnd side was left testing"matcher" in group. An empty matcher is the shaperuns_hook's own docstring cites as realistic, written by hand or through the/hooksUI.The fix is the SessionEnd counterpart of
matcher_sees_bash: a matcher that is absent, empty or*covers every exit reason and is not a defect, and only a matcher naming specific reasons is. Found by a local strict review pass on #1632.