quickwit-oss/quickwit · error
`--wait` and `--force` are mutually exclusive options
Error message
`--wait` and `--force` are mutually exclusive options
What it means
Argument validation in `parse_ingest_args` detected that both `--wait` and `--force` were passed on the `quickwit index ingest` command line. These flags express contradictory ingest commit policies (block until committed vs. fire-and-forget), so the guard rejects the combination before any ingest starts.
Solutions
- Keep only `--wait` if you want ingest to block until documents are committed
- Keep only `--force` if you want ingest to proceed without waiting for commits
- Drop both flags to use the default behavior
Defensive patterns
Strategy: validation
When it happens
Trigger: Thrown at quickwit/quickwit-cli/src/index.rs:393 when the library encounters an invalid state.
Common situations: See trigger scenarios.
AI-assisted analysis of quickwit-oss/quickwit@a39730c5cd (2026-09-08).
Data as JSON: /api/errors/aecde78f12b4d7e5.
Report an issue: GitHub.
Appendix: source
Thrown at quickwit/quickwit-cli/src/index.rs:393
.expect("`index` should be a required arg");
let input_path_opt = if let Some(input_path) = matches.remove_one::<String>("input-path") {
Uri::from_str(&input_path)?
.filepath()
.map(|path| path.to_path_buf())
} else {
None
};
let detailed_response: bool = matches.get_flag("detailed-response");
let batch_size_limit_opt = matches
.remove_one::<String>("batch-size-limit")
.map(|limit| limit.parse::<ByteSize>())
.transpose()
.map_err(|error| anyhow!(error))?;
let commit_type = match (matches.get_flag("wait"), matches.get_flag("force")) {
(false, false) => CommitType::Auto,
(false, true) => CommitType::Force,
(true, false) => CommitType::WaitFor,
(true, true) => bail!("`--wait` and `--force` are mutually exclusive options"),
};
if commit_type == CommitType::Auto && client_args.commit_timeout.is_some() {
bail!("`--commit-timeout` can only be used with --wait or --force options");
}
Ok(Self::Ingest(IngestDocsArgs {
client_args,
index_id,
input_path_opt,
batch_size_limit_opt,
commit_type,
detailed_response,
}))
}
fn parse_search_args(mut matches: ArgMatches) -> anyhow::Result<Self> {
let index_id = matchesView on GitHub (pinned to a39730c5cd)