algonaut 0.5.0

A Rusty sdk for the Algorand blockchain.
Documentation
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
use std::fmt::Debug;

use algonaut_indexer::apis;
use thiserror::Error;

#[derive(Error, Debug, Clone)]
pub enum IndexerError {
    /// General text-only errors. Dedicated error variants can be created, if needed.
    #[error("Msg: {0}")]
    Msg(String),
}

impl<T: Debug> From<apis::Error<T>> for IndexerError {
    fn from(error: apis::Error<T>) -> Self {
        IndexerError::Msg(format!("{:?}", error))
    }
}