Surfaced by the 4-reviewer fan-out on PR #422 (issue #376). Deferred as a Minor — current behavior is correct and documented.
Current behavior
--count and --exists are both accepted together (both live on _common_parser). --exists wins via the documented precedence chain in render() (exists > count > fields > detail) and _emit's exit-code check:
$ jrag find Foo --count --exists
true # --exists output; exit 0/2 on hit/miss
No warning, no error — a user who passes both almost certainly meant only one.
Proposal
Make them mutually exclusive at parse time:
shape = common.add_mutually_exclusive_group()
shape.add_argument("--count", action="store_true", ...)
shape.add_argument("--exists", action="store_true", ...)
Related
--fields is also a no-op when combined with --count/--exists (it shapes node projection, which those bypass). As of #422 that's documented in --help and the skill/agent docs, but not enforced. A mutex can't cover --fields (it's a different axis — a normal-projection override), so it stays a documented no-op.
Priority
Low — defer unless a user actually trips over it. Filing so it's tracked.
Surfaced by the 4-reviewer fan-out on PR #422 (issue #376). Deferred as a Minor — current behavior is correct and documented.
Current behavior
--countand--existsare both accepted together (both live on_common_parser).--existswins via the documented precedence chain inrender()(exists>count>fields>detail) and_emit's exit-code check:No warning, no error — a user who passes both almost certainly meant only one.
Proposal
Make them mutually exclusive at parse time:
Related
--fieldsis also a no-op when combined with--count/--exists(it shapes node projection, which those bypass). As of #422 that's documented in--helpand the skill/agent docs, but not enforced. A mutex can't cover--fields(it's a different axis — a normal-projection override), so it stays a documented no-op.Priority
Low — defer unless a user actually trips over it. Filing so it's tracked.