Repository navigation
[pull] main from DeusData:main - #138
Merged
Merged
Conversation
Hermes `install` failed with `op=pre_llm_hook_install` whenever config.yaml held a PLAIN scalar with a `>` or `|` anywhere after the value start — `probe: kaomoji face >w< here` — while the identical string double-quoted, or a mid-value `*`, installed fine. An agent-config failure aborts activation, so the whole install exited 1 and user-PATH registration was skipped although eleven other agents had configured cleanly. Bisected by @ukind, key by key and persona by persona, down to two persona strings (#1924, continuing #1631/#1656). Root cause: yaml_sequence_line_has_unsupported — the document validator on the mapping-sequence path that the hook upsert/remove uses — ran a second scan after the shared yaml_range_has_unsupported_ex and returned "unsupported" for `[`, `]`, `|` and `>` at ANY position of a plain scalar. The mapping-body path (mcp_servers) never had that check, which is exactly why the mcp op succeeded and only the hook op failed on the same file. Fix: the positional rule the `*`/`&` fix (v0.10.4) and the quote fix (#1631, v0.10.6) already use — an indicator counts only where a NODE begins (range start, after a mapping colon, after a block-sequence dash). Interior ones are text. `probe: >`, `probe: |`, `probe: >-` and `probe: [a, b]` still begin a value and stay unsupported, byte-identically. `[`/`]` get the same treatment on purpose: in block context they are ordinary characters inside a plain scalar (`a: b[0]` parses as the string `b[0]`), a value-start `[` still opens a flow sequence and stays refused (the #1631 line: exact `[]` accepted, non-empty flow sequences unsupported), and the mapping-body path already accepted them mid-value — leaving the sequence scan stricter would keep the mcp-op-passes / hook-op-fails asymmetry this issue is about. Known conservative residue, shared with the `*` rule: a plain-scalar CONTINUATION line that itself starts with one of these characters is still refused (nothing precedes it on its line). Tests (tests/test_config_yaml_edit.c): three accept cases run both real Hermes ops (mcp_servers + pre_llm_call) against a persona corpus with a mid-value `>`, `|` and `[]` and require the original document to survive as an untouched prefix; two pins keep value-start block scalars and a non-empty flow sequence refused with the file byte-identical. RED on the unfixed editor: 61 passed, 3 failed (`yaml_hermes_hook_upsert(&fixture) == -1`); GREEN: 64 passed; RED again with the production change reverted. config_yaml_edit 64 · yaml 73 · cli 306 — 443 passed, 0 failed (macOS, ASan/UBSan test build). Not in this change: the refusal still reaches the user as `op=pre_llm_hook_install path=... (target: regular file, N bytes)` with no reason. The editor collapses every one of its ~236 YAML_ERROR sites into CBM_YAML_IDENTITY_EDIT_ERROR, so naming the refusing rule needs a detailed variant with a typed failure out-parameter, the shape the Codex TOML hook path already has (cbm_toml_codex_hook_failure_t + record_agent_config_error_with_reason). Follow-up. Fixes #1924. Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com> Signed-off-by: Martin Vogel <martin.vogel.tech@gmail.com>
…icators fix(yaml): scope > | [ ] indicators to the value start so Hermes configs install (#1924)
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
See Commits and Changes for more details.
Created by
pull[bot] (v2.0.0-alpha.4)
Can you help keep this open source service alive? 💖 Please sponsor : )