Handling errors in RPC Tokio tasks #502
Labels
bug
Something isn't working
code quality
Improves code quality while not affecting any other
P-Low
Priority: Low
question
Further information is requested
Milestone
Issue Description
Tokio tasks used in some RPC functions returns
Result
. But the handle of those tasks are never checked for errors after they finish. Possible errors are only related to Tokio channels and these errors can be discovered while testing. But because these errors are silent, developer might have a hard time finding the errors.Example code:
clementine/core/src/rpc/verifier.rs
Lines 376 to 388 in da079a8
There are multiple possible solutions to this.
Possible Solutions
except()
callsErr
#[tracing::instrument]
so that tracing handles thisThe text was updated successfully, but these errors were encountered: