{"record":{"id":"0173d257c96fa68b","repo":"quickwit-oss/quickwit","slug":"invalid-boolean-value","errorCode":null,"errorMessage":"invalid boolean value","messagePattern":"invalid boolean value","errorType":"exception","errorClass":null,"httpStatus":null,"severity":"error","filePath":"quickwit/quickwit-indexing/src/actors/packager.rs","lineNumber":249,"sourceCode":"            max_terms\n        );\n    }\n    let mut terms = Vec::with_capacity(num_terms);\n    for inv_index in inv_indexes {\n        let mut terms_streamer = inv_index.terms().stream()?;\n        while let Some((term_data, _)) = terms_streamer.next() {\n            let term = match named_field.field_type {\n                FieldType::U64(_) => u64_from_term_data(term_data)?.to_string(),\n                FieldType::I64(_) => {\n                    tantivy::u64_to_i64(u64_from_term_data(term_data)?).to_string()\n                }\n                FieldType::F64(_) => {\n                    tantivy::u64_to_f64(u64_from_term_data(term_data)?).to_string()\n                }\n                FieldType::Bool(_) => match u64_from_term_data(term_data)? {\n                    0 => false,\n                    1 => true,\n                    _ => bail!(\"invalid boolean value\"),\n                }\n                .to_string(),\n                FieldType::Bytes(_) => {\n                    bail!(\"tags collection is not allowed on `bytes` fields\")\n                }\n                _ => std::str::from_utf8(term_data)?.to_string(),\n            };\n            terms.push(term);\n        }\n    }\n    Ok(terms)\n}\n\nfn create_packaged_split(\n    index_meta: &IndexMeta,\n    split: IndexedSplit,\n    tag_fields: &[NamedField],\n    ctx: &ActorContext<Packager>,","sourceCodeStart":231,"sourceCodeEnd":267,"githubUrl":"https://github.com/quickwit-oss/quickwit/blob/a39730c5cdcd1a4fe798403737ae293999ea21f8/quickwit/quickwit-indexing/src/actors/packager.rs#L231-L267","documentation":"When converting boolean tag terms, the packed u64 term data must be 0 (false) or 1 (true). Any other value is a corrupted or unexpected term encoding for a `bool` field, so `try_extract_terms` bails with this message.","triggerScenarios":"Extracting terms for a tag field of type `bool` in `create_packaged_split` when `u64_from_term_data` yields a value other than 0 or 1 — indicating corrupted term storage or a type/encoding mismatch.","commonSituations":"Corrupted split files; schema drift where the field was previously another numeric type and old terms are decoded as bool; a tantivy version/encoding change.","solutions":["Inspect/repair the split's term dictionary; the term data is inconsistent with a bool field.","Re-index the affected data into a fresh split to regenerate terms.","Verify the index schema field type hasn't changed between split generations."],"exampleFix":null,"handlingStrategy":"validation","validationCode":"fn is_valid_bool_term(v: u64) -> bool { matches!(v, 0 | 1) }\n// call before term extraction if you control term building\nif !is_valid_bool_term(raw) { return Err(\"corrupt bool term\".into()); }","typeGuard":null,"tryCatchPattern":null,"preventionTips":["Keep field types stable across an index's lifetime to avoid mixed encodings.","Verify split integrity (checksums) if this error appears — it usually means corruption.","Re-index data rather than merging splits from suspect sources."],"tags":["packaging","tags","boolean","corruption"],"backgroundTag":"invalid-argument-value","analyzedSha":"a39730c5cdcd1a4fe798403737ae293999ea21f8","analyzedAt":"2026-09-08T13:19:37.784Z","contentChangedAt":"2026-09-08T13:19:37.784Z","schemaVersion":2},"datasetVersion":"2026-09-14T11:17:12.474Z"}