You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Unify negative-multiplicity errors into EvalError::MultiplicityError
Replace the scattered "internal error: ..." messages raised on
negative/non-positive/non-monotonic multiplicities and inconsistent
accumulators with a single structured EvalError variant,
MultiplicityError { kind, code_place, detail }.
The new Display does not use the "internal error:" prefix; it names the
likely root cause (invalid data in a Materialize source, caused either
by a bug in the external system feeding the source or by a bug in
Materialize) and mentions incorrect usage of the repeat_row table
function as a secondary cause.
Migrated sites:
* src/compute/src/render/reduce.rs (DistinctBy, ReduceInaccumulable,
ReduceMinsMaxes, MinsMaxesHierarchical, hierarchical mins-maxes final,
ReduceMonotonic, AccumulableErrorCheck net-zero + unsigned-sum).
* src/compute/src/render/top_k.rs (MonotonicTopK, TopK validator,
MonotonicTop1).
* src/compute/src/compute_state.rs (persist peek, index peek error
trace) and compute_state/peek_result_iterator.rs (index peek ok
trace), using err.to_string() to feed PeekResponse::Error.
* src/adapter/src/coord/peek.rs and src/adapter/src/peek_client.rs
constant-result fast paths: emit EvalError::MultiplicityError instead
of a hand-rolled InvalidParameterValue / AdapterError::Unstructured.
* src/storage-operators/src/s3_oneshot_sink.rs: build and stringify
a MultiplicityError, mirroring the [customer-data] logging contract
inline (storage-operators cannot depend on compute).
* src/expr/src/relation/func.rs (scalar-subquery cardinality check):
the old EvalError::NegativeRowsFromSubquery variant is removed.
Internal error reporting is unified: every MultiplicityError site logs
through log_multiplicity_error (free function in render/errors.rs, and
a thin forwarding method on ErrorLogger). All sites share the static
title "invalid record multiplicity", so they merge into a single Sentry
group; kind/code_place/detail go into a [customer-data]-tagged WARN
breadcrumb.
Additionally fix the reduce.rs monoid-variant mismatch site: the lhs/rhs
Row values no longer leak into the panic/Sentry title; a static title
helps with Sentry's issue merging.
Proto backcompat is not needed for EvalError::NegativeRowsFromSubquery
because it was introduced this week and hasn't shipped in any release;
its proto tag (83) is reused by the new ProtoMultiplicityError.
Co-authored-by: Junie <junie@jetbrains.com>
0 commit comments