Define shared search filtering, grouping, and ordering #27
No reviewers
Labels
No labels
area/cli
area/core
area/database
area/indexing
area/query
type/epic
type/feature
type/foundation
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set
Reference
JayKobe6k/ClariTree!27
Loading…
Reference in a new issue
No description provided.
Delete branch "issue-13-shared-search-pipeline"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Summary
Tests
nix develop --command cargo fmt --all -- --checknix develop --command cargo lintnix develop --command cargo test --all-targets --all-featuresnix develop --command cargo doc --no-deps --all-featuresnix develop --command cargo check --all-targets --all-features --target x86_64-pc-windows-gnugit diff --checkDepends on #25.
Closes #13.
Found two actionable search-pipeline defects.
@ -0,0 +469,4 @@structure: Option<String>,enumeration: Option<String>,canonical_type: Option<String>,source_anchor: SearchSourceAnchor,[P2] This requires a source anchor for every hit, but the value contract permits anchorless definitions and issue #10 explicitly requires merge handles, identified by an occurrence anchor or ordinal, to be returned by search. An ordinal control-flow merge therefore cannot be mapped faithfully without dropping it or inventing source provenance, making value search incomplete or misleading. Please represent source-or-ordinal/missing provenance and define its tie-break and JSON behavior.
@ -0,0 +787,4 @@});}for field in &request.group_by {validate_field(request.target, *field, "--group-by")?;[P3] This validates only applicability, leaving grouping depth unbounded. Against this head, a one-hit probe with 5,000 repeated
SearchField::Typeterms was accepted andexecuteaborted with a stack overflow; the CLI also accepts an unbounded grouping vector. Please reject duplicate/excess grouping terms during preparation, naturally limiting depth to six distinct fields, or make grouping and rendering iterative.Review comment #1074: Fixed in
ad33903. Value search hits now retain the typedValueOccurrenceSite, including both source anchors plus structural ordinal or a source-less semantic ordinal; deterministic ties and tagged JSON include that provenance. Regressions includevalue_sites_order_by_source_discriminator_then_source_less_ordinalandsearch_json_tags_source_less_value_ordinals_without_inventing_source; full validation passed.Review comment #1078: Fixed in
ad33903.PreparedSearchPlannow rejects duplicate grouping fields, so the closed six-field enum bounds grouping recursion. Regressions:duplicate_grouping_fields_are_rejected_and_distinct_fields_bound_depthandservice_rejects_duplicate_grouping_before_catalog_or_repository_access; full all-target/all-feature tests, lint, rustdoc, Windows target check, and diff check passed.