Enum pinecone_rs::error::Error
source · #[non_exhaustive]pub enum Error {
ArgumentError {
name: String,
found: String,
expected: String,
},
ReqwestError(Error),
ReqwestResponseError(StatusCode, Error),
PineconeResponseError(StatusCode, Option<PineconeErrorResponse>, Option<String>),
PineconeError(Response),
VectorDimensionError {
found: u32,
expected: u32,
id: String,
},
URLNotAvailable,
UnsupportedMethod {
method: Method,
},
}
Expand description
A set of errors that can occur in the Pinecone Client.
Variants (Non-exhaustive)§
This enum is marked as non-exhaustive
Non-exhaustive enums could have additional variants added in future. Therefore, when matching against variants of non-exhaustive enums, an extra wildcard arm must be added to account for any future variants.
ArgumentError
Fields
An error for when an invalid argument is used / given.
ReqwestError(Error)
This is the error used when request fails to make a request.
ReqwestResponseError(StatusCode, Error)
An error returned when reqwest fails to do an action while the overall request is. successfull, it is used currently for when a request goes through but a json decode fails.
PineconeResponseError(StatusCode, Option<PineconeErrorResponse>, Option<String>)
When pinecone sends their PineconeErrorResponse
to the client.
PineconeError(Response)
This error is used when Pinecone fails to return a PineconeErrorResponse
VectorDimensionError
Fields
An error that describes an incorrectly sized vector.
URLNotAvailable
An error used for when the url value within an IndexDescription can’t be found.
UnsupportedMethod
This is an internal error used for internal checks. This should never actually happen.
Trait Implementations§
source§impl Error for Error
impl Error for Error
1.30.0 · source§fn source(&self) -> Option<&(dyn Error + 'static)>
fn source(&self) -> Option<&(dyn Error + 'static)>
The lower-level source of this error, if any. Read more
1.0.0 · source§fn description(&self) -> &str
fn description(&self) -> &str
👎Deprecated since 1.42.0: use the Display impl or to_string()
Auto Trait Implementations§
impl !RefUnwindSafe for Error
impl Send for Error
impl Sync for Error
impl Unpin for Error
impl !UnwindSafe for Error
Blanket Implementations§
source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more