Skip to content

fix: add missing clap attribute to no_content_indexing (#754) - #765

Merged
dmtrKovalenko merged 1 commit into
mainfrom
triage-bot/issue-754
Aug 11, 2026
Merged

fix: add missing clap attribute to no_content_indexing (#754)#765
dmtrKovalenko merged 1 commit into
mainfrom
triage-bot/issue-754

Conversation

@gustav-fff

Copy link
Copy Markdown
Collaborator

Closes #754

Root cause

crates/fff-mcp/src/main.rs:134 declared the no_content_indexing: bool field without an #[arg(long = ...)] attribute. clap therefore treated it as a positional argument with a SetTrue action, which is invalid.

Fix

Added #[arg(long = "no-content-indexing")] to the field, matching the adjacent --no-warmup / --no-watch flags.

Steps to reproduce

On pre-fix origin/main (b6f351d):

cargo run -p fff-mcp -- --help

Expected: help text listing a --no-content-indexing boolean option.

Actual (debug build): panic before any output —

thread 'main' panicked at clap_builder-4.6.0/src/builder/debug_asserts.rs:746:9:
Argument 'no_content_indexing' is positional and it must take a value but action is SetTrue

Release builds instead expose [NO_CONTENT_INDEXING] as a positional and reject --no-content-indexing.

How verified

cargo run -p fff-mcp -- --help

Now exits 0 and lists the flag:

      --no-content-indexing
          Disable the content index built after the initial scan.
          This makes grep calls slower but consumes less RAM (recommended to not turn off)

Automated triage via Gustav. Honk-Honk 🪿

The no_content_indexing field lacked its #[arg(long = ...)] attribute,
so clap treated it as a positional with a SetTrue action. Debug builds
panicked on any invocation; release builds exposed [NO_CONTENT_INDEXING]
as a positional and rejected --no-content-indexing.

Closes #754
@coderabbitai

coderabbitai Bot commented Aug 11, 2026

Copy link
Copy Markdown

Important

Review skipped

Auto reviews are disabled on base/target branches other than the default branch.

Please check the settings in the CodeRabbit UI or the .coderabbit.yaml file in this repository. To trigger a single review, invoke the @coderabbitai review command.

⚙️ Run configuration

Configuration used: defaults

Review profile: CHILL

Plan: Pro Plus

Run ID: 1a7f21ad-0383-47e1-a7f6-6aa3af43058a

You can disable this status message by setting the reviews.review_status to false in the CodeRabbit configuration file.

Use the checkbox below for a quick retry:

  • 🔍 Trigger review

Comment @coderabbitai help to get the list of available commands.

@dmtrKovalenko
dmtrKovalenko merged commit dd87489 into main Aug 11, 2026
53 checks passed
abhijit-s pushed a commit to abhijit-s/fff that referenced this pull request Aug 13, 2026
Brings in upstream fixes on top of our 0.18.0 fork:
- fix(grep) dmtrKovalenko#756/dmtrKovalenko#764: literal/regex fallback now keeps an explicit
  FilePath scope so a top-level regex alternation can't leak matches
  outside the pinned path
- fix dmtrKovalenko#754/dmtrKovalenko#765: missing clap attribute on no_content_indexing
- fix(bun) dmtrKovalenko#766: proper build step for fff-bun
- chore dmtrKovalenko#762: rename stale fff.nvim repo refs to fff

Conflicts resolved preserving fork divergences:
- update_check.rs / install-mcp.sh: kept our DEFAULT_REPO=abhijit-s/fff
  and FFF_UPDATE_REPO override; upstream's fff.nvim->fff rename does not
  apply since we target our own fork for update checks and installs
- README.md: kept our rewritten Homebrew-tap/apt/fffctl install section;
  upstream only tweaked a release URL in a block our fork already removed
- grep_tests.rs: add/add at EOF resolved as a union — kept our three
  cold-start readiness tests and adopted upstream's dmtrKovalenko#756 regex-scope test,
  reflowing the shared trailing braces so both functions close correctly

grep.rs auto-merged; reviewed the dmtrKovalenko#756 fallback change against our
surrounding fork logic and confirmed coherence. Makefile .PHONY targets
and the per-root ignore feature (ignore.rs/main.rs) preserved; workspace
stays at 0.18.0. Build green (fff-mcp/fff-engine/fff-ctl); fff-search +
fff-engine tests 375 passed, 0 failed.
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.

[Bug]: no_content_indexing is parsed as a positional argument

2 participants