use crate::mempool::MempoolError;
use tari_comms_dht::outbound::DhtOutboundError;
use tari_service_framework::reply_channel::TransportChannelError;
use thiserror::Error;
#[derive(Debug, Error)]
pub enum MempoolServiceError {
#[error("DHT outbound error: `{0}`")]
DhtOutboundError(#[from] DhtOutboundError),
#[error("Invalid request error: `{0}`")]
InvalidRequest(String),
#[error("Invalid response error: `{0}`")]
InvalidResponse(String),
#[error("Request timed out error")]
RequestTimedOut,
#[error("No bootstrap nodes configured error")]
NoBootstrapNodesConfigured,
#[error("Outbound message service error: `{0}`")]
OutboundMessageService(String),
#[error("Mempool error: `{0}`")]
MempoolError(#[from] MempoolError),
#[error("Unexpected API response error")]
UnexpectedApiResponse,
#[error("Transport channel error: `{0}`")]
TransportChannelError(#[from] TransportChannelError),
#[error("Failed to send broadcast message")]
BroadcastFailed,
}