rsiot/components/cmp_websocket_client/
error.rs

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
#[derive(Debug, thiserror::Error)]
pub enum Error<TMessage> {
    #[error("Error from tunstenite: {source}")]
    Tungstenite {
        #[from]
        source: tokio_tungstenite::tungstenite::Error,
    },

    #[error("{source}")]
    TokioTaskJoin {
        #[from]
        source: tokio::task::JoinError,
    },

    #[error("{source}")]
    TokioMpscSend {
        #[from]
        source: tokio::sync::mpsc::error::SendError<TMessage>,
    },

    #[error("fn_input error: {0}")]
    FnInput(anyhow::Error),

    #[error("fn_output error: {0}")]
    FnOutput(anyhow::Error),

    #[error(transparent)]
    CmpOutput(crate::executor::ComponentError),

    #[error(transparent)]
    BadUrl(url::ParseError),
}