Fix the format and linter error

This commit is contained in:
Gnosnay 2024-12-28 20:35:32 +08:00
parent 44eb153619
commit 525e67ba93
7 changed files with 9 additions and 7 deletions

View File

@ -34,7 +34,9 @@ use meilisearch_types::milli::documents::{obkv_to_object, DocumentsBatchReader,
use meilisearch_types::milli::heed::CompactionOption;
use meilisearch_types::milli::progress::Progress;
use meilisearch_types::milli::update::new::indexer::{self, UpdateByFunction};
use meilisearch_types::milli::update::{DocumentAdditionResult, IndexDocumentsMethod, Settings as MilliSettings};
use meilisearch_types::milli::update::{
DocumentAdditionResult, IndexDocumentsMethod, Settings as MilliSettings,
};
use meilisearch_types::milli::vector::parsed_vectors::{ExplicitVectors, VectorOrArrayOfVectors};
use meilisearch_types::milli::{self, Filter, ThreadPoolNoAbortBuilder};
use meilisearch_types::settings::{apply_settings_to_builder, Settings, Unchecked};

View File

@ -1,6 +1,7 @@
use crate::option::Opt;
use clap::Parser;
use crate::option::Opt;
#[test]
fn test_valid_opt() {
assert!(Opt::try_parse_from(Some("")).is_ok());

View File

@ -176,7 +176,7 @@ impl From<AscDescError> for SortError {
AscDescError::ReservedKeyword { name } if name.starts_with("_geoPoint") => {
SortError::BadGeoPointUsage { name }
}
AscDescError::ReservedKeyword { name } if &name == RESERVED_GEO_FIELD_NAME => {
AscDescError::ReservedKeyword { name } if name == RESERVED_GEO_FIELD_NAME => {
SortError::ReservedNameForSettings { name }
}
AscDescError::ReservedKeyword { name } if name.starts_with("_geoRadius") => {

View File

@ -4,7 +4,8 @@ use std::collections::HashMap;
use serde::{Deserialize, Serialize};
use crate::{constants::RESERVED_VECTORS_FIELD_NAME, FieldId, FieldsIdsMap, Weight};
use crate::constants::RESERVED_VECTORS_FIELD_NAME;
use crate::{FieldId, FieldsIdsMap, Weight};
#[derive(Debug, Default, Serialize, Deserialize)]
pub struct FieldidsWeightsMap {

View File

@ -21,7 +21,6 @@ use crate::heed_codec::facet::{
use crate::heed_codec::{BEU16StrCodec, FstSetCodec, StrBEU16Codec, StrRefCodec};
use crate::order_by_map::OrderByMap;
use crate::proximity::ProximityPrecision;
use crate::vector::{ArroyWrapper, Embedding, EmbeddingConfig};
use crate::{
default_criteria, CboRoaringBitmapCodec, Criterion, DocumentId, ExternalDocumentsIds,

View File

@ -49,8 +49,8 @@ pub use self::geo_sort::Strategy as GeoSortStrategy;
use self::graph_based_ranking_rule::Words;
use self::interner::Interned;
use self::vector_sort::VectorSort;
use crate::index::PrefixSearch;
use crate::constants::RESERVED_GEO_FIELD_NAME;
use crate::index::PrefixSearch;
use crate::localized_attributes_rules::LocalizedFieldIds;
use crate::score_details::{ScoreDetails, ScoringStrategy};
use crate::search::new::distinct::apply_distinct_rule;

View File

@ -27,7 +27,6 @@ pub use self::enrich::{extract_finite_float_from_value, DocumentId};
pub use self::helpers::*;
pub use self::transform::{Transform, TransformOutput};
use super::new::StdResult;
use crate::documents::{obkv_to_object, DocumentsBatchReader};
use crate::error::{Error, InternalError};
use crate::index::{PrefixSearch, PrefixSettings};