This repository was archived by the owner on Nov 15, 2023. It is now read-only.
File tree Expand file tree Collapse file tree 2 files changed +12
-12
lines changed Expand file tree Collapse file tree 2 files changed +12
-12
lines changed Original file line number Diff line number Diff line change @@ -51,13 +51,13 @@ mod columns {
51
51
#[ derive( Debug , Error ) ]
52
52
enum Error {
53
53
#[ error( transparent) ]
54
- Erasure ( erasure:: Error ) ,
54
+ Erasure ( # [ from ] erasure:: Error ) ,
55
55
#[ error( transparent) ]
56
- Io ( io:: Error ) ,
56
+ Io ( # [ from ] io:: Error ) ,
57
57
#[ error( transparent) ]
58
- Oneshot ( oneshot:: Canceled ) ,
58
+ Oneshot ( # [ from ] oneshot:: Canceled ) ,
59
59
#[ error( transparent) ]
60
- Subsystem ( SubsystemError ) ,
60
+ Subsystem ( # [ from ] SubsystemError ) ,
61
61
}
62
62
63
63
/// An implementation of the Availability Store subsystem.
Original file line number Diff line number Diff line change @@ -73,15 +73,15 @@ enum Error {
73
73
CandidateNotFound ,
74
74
#[ error( "Signature is invalid" ) ]
75
75
InvalidSignature ,
76
- #[ error( "Storing data was not successful" ) ]
77
- StoreFailed ,
78
- #[ error( transparent) ]
79
- Erasure ( erasure_coding:: Error ) ,
76
+ #[ error( "Storing data failed" ) ]
77
+ StoreFailed ( oneshot:: Canceled ) ,
78
+ #[ error( "Responding to backing request failed" ) ]
79
+ BackingResponseChannel ( oneshot:: Canceled ) ,
80
+ #[ error( "Obtaining erasure chunks failed" ) ]
81
+ ObtainErasureChunks ( #[ from] #[ source] erasure_coding:: Error ) ,
80
82
#[ error( transparent) ]
81
83
ValidationFailed ( ValidationFailed ) ,
82
84
#[ error( transparent) ]
83
- Oneshot ( oneshot:: Canceled ) ,
84
- #[ error( transparent) ]
85
85
Mpsc ( mpsc:: SendError ) ,
86
86
#[ error( transparent) ]
87
87
UtilError ( util:: Error ) ,
@@ -472,7 +472,7 @@ impl CandidateBackingJob {
472
472
CandidateBackingMessage :: GetBackedCandidates ( _, tx) => {
473
473
let backed = self . get_backed ( ) ;
474
474
475
- tx. send ( backed) . map_err ( |_| oneshot :: Canceled ) ?;
475
+ tx. send ( backed) . map_err ( |e| Error :: BackingResponseChannel ( e ) ) ?;
476
476
}
477
477
}
478
478
@@ -643,7 +643,7 @@ impl CandidateBackingJob {
643
643
)
644
644
) . await ?;
645
645
646
- rx. await ?. map_err ( |_ | Error :: StoreFailed ) ?;
646
+ rx. await ?. map_err ( |e | Error :: StoreFailed ( e ) ) ?;
647
647
648
648
Ok ( ( ) )
649
649
}
You can’t perform that action at this time.
0 commit comments