MCPcopy Create free account
hub / github.com/ElementsProject/lightning / fmt

Method fmt

plugins/lsps-plugin/src/cln_adapters/rpc.rs:243–258  ·  view source on GitHub ↗
(&self, f: &mut fmt::Formatter<'_>)

Source from the content-addressed store, hash-verified

241
242impl fmt::Display for DsError {
243 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
244 match self {
245 DsError::NotFound { key } => write!(f, "no datastore entry for key {:?}", key),
246 DsError::MissingValue { key } => write!(
247 f,
248 "datastore entry had neither `string` nor `hex` for key {:?}",
249 key
250 ),
251 DsError::JsonParse { key, source } => {
252 write!(f, "failed to parse JSON at key {:?}: {}", key, source)
253 }
254 DsError::HexDecode { key, source } => {
255 write!(f, "failed to decode hex at key {:?}: {}", key, source)
256 }
257 }
258 }
259}
260
261impl std::error::Error for DsError {}

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected