From 418c5ed7c3edad872ea49e6736568896ccf280e7 Mon Sep 17 00:00:00 2001 From: muzarski Date: Wed, 7 Aug 2024 11:26:27 +0200 Subject: [PATCH] f_errors: remove ParseError --- scylla-cql/src/frame/frame_errors.rs | 3 --- scylla/src/transport/errors.rs | 8 +------- 2 files changed, 1 insertion(+), 10 deletions(-) diff --git a/scylla-cql/src/frame/frame_errors.rs b/scylla-cql/src/frame/frame_errors.rs index 30483eac3..74be0c9cd 100644 --- a/scylla-cql/src/frame/frame_errors.rs +++ b/scylla-cql/src/frame/frame_errors.rs @@ -89,9 +89,6 @@ pub enum FrameHeaderParseError { ConnectionClosed(usize, usize), } -#[derive(Error, Debug)] -pub enum ParseError {} - /// An error that occurred during CQL request serialization. #[non_exhaustive] #[derive(Error, Debug, Clone)] diff --git a/scylla/src/transport/errors.rs b/scylla/src/transport/errors.rs index bc049da12..d00e68de2 100644 --- a/scylla/src/transport/errors.rs +++ b/scylla/src/transport/errors.rs @@ -17,7 +17,7 @@ use scylla_cql::{ CqlAuthChallengeParseError, CqlAuthSuccessParseError, CqlAuthenticateParseError, CqlErrorParseError, CqlEventParseError, CqlRequestSerializationError, CqlResponseParseError, CqlResultParseError, CqlSupportedParseError, - FrameBodyExtensionsParseError, FrameHeaderParseError, ParseError, + FrameBodyExtensionsParseError, FrameHeaderParseError, }, request::CqlRequestKind, response::CqlResponseKind, @@ -99,12 +99,6 @@ impl From for QueryError { } } -impl From for QueryError { - fn from(parse_error: ParseError) -> QueryError { - QueryError::InvalidMessage(format!("Error parsing message: {}", parse_error)) - } -} - impl From for QueryError { fn from(timer_error: tokio::time::error::Elapsed) -> QueryError { QueryError::RequestTimeout(format!("{}", timer_error))