Skip to content

fix: address low follow-ups from the 2026-11-25 issue run - #3985

Merged
dyoshikawa merged 3 commits into
mainfrom
resolve-issue-3971-low-followups
Nov 26, 2026
Merged

dyoshikawa merged 3 commits into
mainfrom
resolve-issue-3971-low-followups

Conversation

@dyoshikawa

@dyoshikawa dyoshikawa commented Nov 26, 2026 •

Copy link
Copy Markdown
Owner

Summary

Picks up the low findings collected in #3971 (plus the two OpenBitFun findings from the #3973 review) where a cheap, defensible fix exists, and records why the rest stay open.

Changes

  • Bob / shared hooks processor: hooks on an event that is already reported as skipped (e.g. a Bob Shell 2.1.0 opt-in event in the shared block) are no longer reported a second and third time as "Skipped -type hook(s)" / "Skipped matcher hook(s)". One helper, emittedHooksOf, now decides which hooks reach the target's file. Its effective view feeds the hook-type and matcher warnings; its canonical view (shared definitions emitted as written) feeds the per-hook enabled / confirm warnings, which previously had their own filter. For targets without dropsUnknownOverrideEvents, an override key that shares a skipped shared event's name is still emitted, so it is still checked. A shared definition replaced by an override key of the same name is no longer counted by the per-hook warnings, because it is not written.
  • OpenBitFun hook matchers: on preToolUse / permissionRequest, a lowercase spelling of a known tool (bash, read) now gets a warning, because OpenBitFun compiles the matcher as a case-sensitive regex anchored to the runtime tool name (native_hooks/settings.rs: Regex::new(&format!("^(?:{raw})$"))). A name that comes after an inline flag group turning on i ((?i), (?is), (?i:...)) and is OpenBitFun's own spelling is not warned about ((?i)read matches Read). (?i)bash still is, since the runtime name is ExecCommand, and so are names before the flag and under (?s) / (?-i). The matcher is not rewritten.
  • OpenBitFun XDG warning on import: import --global now warns about a non-default $XDG_CONFIG_HOME / $XDG_DATA_HOME too, not only generate. Hooks override fromFile (always called on import, even when the file is missing); subagents and skills implement the existing import-only processor hooks (loadAdditionalImportFiles / getConfiguredImportRoots) that return nothing and only warn, so the warning fires even when the default location is empty — the case where the import would otherwise silently find nothing. The warning text now says rulesync "reads and writes" there.
  • Hermes single_instance: Hermes loads config.yaml with PyYAML (YAML 1.1) and reads the key with bool(config.get("single_instance")) (tools/mcp_tool_server_run.py). Before this PR, rulesync silently dropped any non-boolean value, so a hand-written 1 turned the guard off on regenerate. Now the words PyYAML's resolver reads as booleans (yes|no|true|false|on|off, in lower, Capitalized or UPPER case, per yaml/resolver.py) map to that boolean in both directions, so an unquoted single_instance: no stays false. Any other number or string is written as its Python truthiness, with a warning. Any other non-boolean is dropped with a warning.
  • Docs: docs/reference/file-formats.md (OpenBitFun hooks/subagents/skills notes, Hermes note) and the regenerated docs content.

Design decisions

  • The OpenBitFun lowercase check only looks at names starting with a lowercase letter; capitalized unknown names (BASH) are already covered by the existing "not an OpenBitFun built-in tool" warning, so a name is never warned about twice.
  • The XDG warning on import reuses existing import-only extension points instead of adding OpenBitFun branches to the processors or a side effect in getSettablePaths.
  • single_instance mirrors PyYAML plus Python truthiness rather than the yes/no parser used for lazy / events, because that is what upstream does for this key. y / n are not mapped: PyYAML's bool resolver does not include them. A JSON string such as "false" in .rulesync/mcp.json is mapped like the YAML word, which is clearly what its author meant.

Skipped items

  • Pi Windows path forms (\\?\, drive aliases): mirroring oh-my-pi's Windows handling needs its exact semantics verified at the pinned commit and Windows-specific tests; the raw path is already passed as tool_input.path, so a guard can re-check it. Revisit on a user report.
  • Pi SIGKILL orphaning: not fixable in rulesync (the host is killed); already documented.
  • GitLab Duo contrived deny/allow overlap: no defensible general detection for pairs like deny echo '"' vs allow echo ?.
  • Vibe VIBE_AGENT_IGNORED_KEYS / policy-override files kept on delete: waits on upstream publishing a schema.

Refs #3971

🤖 Generated with Claude Code

https://claude.ai/code/session_01JdNNKCxxrKAMDANMGDEGP4

dyoshikawa and others added 3 commits November 26, 2026 16:43
- hooks: do not re-report hooks on an already skipped event (e.g. a Bob
  opt-in event) as skipped hook types or matchers
- openbitfun: warn about tool-gating matchers that spell a known tool in
  another case (bash, read), which OpenBitFun never matches
- openbitfun: warn about a moved XDG config/data home on import --global
  too, not only on generate
- hermesagent: write a non-boolean single_instance as the boolean Hermes
  reads by truthiness instead of silently dropping it

Refs #3971

Co-Authored-By: Claude Opus 5.5 <[email protected]>
Claude-Session: https://claude.ai/code/session_01JdNNKCxxrKAMDANMGDEGP4
- hermesagent: map the words PyYAML reads as booleans (no, off, ...) to
  that boolean for single_instance before falling back to truthiness
- hooks: share one emitted-hooks helper between the hook-type, matcher
  and per-hook field warnings
- openbitfun: detect case-insensitive flag groups precisely and only
  exempt names after the flag

Refs #3971

Co-Authored-By: Claude Opus 5.5 <[email protected]>
Claude-Session: https://claude.ai/code/session_01JdNNKCxxrKAMDANMGDEGP4
…w-followups

# Conflicts:
#	src/generated/docs-content.ts
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