Skip to content

Instant vs range queries diverge on missing-value-data handling for a dual-population group #597

Description

@milindsrivastava1997

`collect_results_separate_keys` (`asap-query-engine/src/engines/simple_engine/mod.rs`, instant-query path) still hard-fails via `.ok_or_else(|| format!("No value for key: {:?}", key))?` when a dual-population group has keys data but no matching value data.

The range query path used to have the identical hard-fail (same shape, same reasoning) until #583's fix changed it: a group with keys data but no value data anywhere in the queried range is now skipped with a `warn!`, and the rest of the range query still succeeds, instead of the one missing group poisoning every other group's results.

This was a deliberate decision for the range path (per #583's design discussion, "Q6") but was never applied to the instant path, so the two paths now diverge on identical data shapes: an instant query with an orphaned dual-population group fails entirely; the equivalent range query silently skips just that group and returns the rest.

Not obviously a bug either way, but worth a conscious decision rather than accidental drift — exactly the kind of thing #581 (broader instant/range unification) is about. Options:

  1. Bring the instant path in line with range's skip-with-warn behavior.
  2. Revert to symmetry the other way (make range hard-fail again) — unlikely to be wanted, since the whole point of Range query key expansion uses one snapshot instead of per-step keys #583's Q6 was that a hard-fail here is disproportionate.
  3. Leave as an intentional, documented asymmetry if there's a reason instant queries specifically should still fail loudly here.

Related: #581, #583.

Metadata

Metadata

Labels

No labels
No labels

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions