quickwit-oss/quickwit · error · anyhow::Error
timestamp field `{timestamp_field_path}` should not end with
Error message
timestamp field `{timestamp_field_path}` should not end with a `.` What it means
The mirror check of error 64: `validate_timestamp_field` rejects a `timestamp_field` path that ends with a `.`. A trailing dot cannot terminate a valid field name, so the DocMapper builder bails during `try_from`.
Source
Thrown at quickwit/quickwit-doc-mapper/src/doc_mapper/doc_mapper_impl.rs:109
/// Maximum number of partitions
max_num_partitions: NonZeroU32,
/// Defines how unmapped fields should be handle.
mode: Mode,
/// User-defined tokenizers.
tokenizer_entries: Vec<TokenizerEntry>,
/// Tokenizer manager.
tokenizer_manager: TokenizerManager,
}
fn validate_timestamp_field(
timestamp_field_path: &str,
mapping_root_node: &MappingNode,
) -> anyhow::Result<()> {
if timestamp_field_path.starts_with('.') || timestamp_field_path.starts_with("\\.") {
bail!("timestamp field `{timestamp_field_path}` should not start with a `.`");
}
if timestamp_field_path.ends_with('.') {
bail!("timestamp field `{timestamp_field_path}` should not end with a `.`");
}
let Some(timestamp_field_type) =
mapping_root_node.find_field_mapping_type(timestamp_field_path)
else {
bail!("could not find timestamp field `{timestamp_field_path}` in field mappings");
};
if let FieldMappingType::DateTime(date_time_option, cardinality) = ×tamp_field_type {
if cardinality != &Cardinality::SingleValued {
bail!("timestamp field `{timestamp_field_path}` should be single-valued");
}
if !date_time_option.fast {
bail!("timestamp field `{timestamp_field_path}` should be a fast field");
}
} else {
bail!("timestamp field `{timestamp_field_path}` should be a datetime field");
}
Ok(())
}View on GitHub (pinned to a39730c5cd)
Solutions
- Strip the trailing `.` from `timestamp_field` in the index config.
- Fix the path-joining code/config template so it does not append a separator after the final segment.
- Validate the index config before applying it.
Example fix
// before doc_mapping: timestamp_field: "event." // after doc_mapping: timestamp_field: "event.time"
Defensive patterns
Strategy: validation
Validate before calling
const ts = config.doc_mapping.timestamp_field;
if (typeof ts === 'string' && ts.endsWith('.')) {
throw new Error(`timestamp_field "${ts}" must not end with a dot`);
} Type guard
fn is_valid_trailing_path(p: &str) -> bool { !p.ends_with('.') } Try / catch
match DocMapperBuilder::try_from(config) {
Ok(dm) => Ok(dm),
Err(e) if e.to_string().contains("should not end with") => Err(ConfigError::InvalidTimestampField(e.to_string())),
Err(e) => Err(e.into()),
} Prevention
- Trim separators when joining path segments programmatically.
- Lint index configs for trailing dots in field paths.
- Copy paths from the mapping definition, not by hand.
When it happens
Trigger: Calling `DocMapperBuilder::try_from` with `doc_mapping.timestamp_field` ending in `.` (e.g. `"timestamp."`), typically from concatenating path segments incorrectly.
Common situations: Programmatic config generation joining keys with `.` and leaving a trailing separator; copy-paste artifacts in index config YAML; template rendering issues in config tooling.
Understand the failure class
Background: "Invalid value" and "allowed values are" config errors: what your library rejected and how to fix it — this error's family across 41 libraries.
Related errors
- timestamp field `{timestamp_field_path}` should not start wi
- could not find timestamp field `{timestamp_field_path}` in f
- timestamp field `{timestamp_field_path}` should be single-va
- timestamp field `{timestamp_field_path}` should be a fast fi
- timestamp field `{timestamp_field_path}` should be a datetim
AI-assisted analysis of quickwit-oss/quickwit@a39730c5cd (2026-09-08).
Data as JSON: /api/errors/86bde8e21399bf79.
Report an issue: GitHub.