@@ -50,9 +50,10 @@ impl std::fmt::Display for ChunkType {
5050#[ derive( thiserror:: Error , Debug ) ]
5151pub enum ChunkRetrievalError {
5252 #[ error(
53- "Failed to retrieve chunk ({submission_prefix}, {chunk_index}, {chunk_type}) from object store: {source} "
53+ "Failed to retrieve chunk ({submission_prefix}, {chunk_index}, {chunk_type}) from object store"
5454 ) ]
5555 ObjectStoreError {
56+ #[ source]
5657 source : object_store:: Error ,
5758 submission_prefix : Box < str > ,
5859 chunk_index : chunk:: ChunkIndex ,
@@ -63,19 +64,21 @@ pub enum ChunkRetrievalError {
6364#[ derive( thiserror:: Error , Debug ) ]
6465pub enum ChunkStorageError {
6566 #[ error(
66- "Failed to store chunk ({submission_prefix}, {chunk_index}, {chunk_type}) to object store: {source} "
67+ "Failed to store chunk ({submission_prefix}, {chunk_index}, {chunk_type}) to object store"
6768 ) ]
6869 ObjectStoreError {
70+ #[ source]
6971 source : object_store:: Error ,
7072 submission_prefix : Box < str > ,
7173 chunk_index : chunk:: ChunkIndex ,
7274 chunk_type : ChunkType ,
7375 } ,
74- #[ error( "Failed to read chunk element from stream/iterator at index {chunk_index}: " ) ]
76+ #[ error( "Failed to read chunk element from stream/iterator at index {chunk_index}" ) ]
7577 ChunkContentsEvalError {
7678 submission_prefix : Box < str > ,
7779 chunk_index : chunk:: ChunkIndex ,
7880 chunk_type : ChunkType ,
81+ #[ source]
7982 source : anyhow:: Error ,
8083 } ,
8184}
@@ -84,19 +87,20 @@ pub enum ChunkStorageError {
8487pub enum ChunksStorageError {
8588 #[ error( transparent) ]
8689 ChunkStorageError ( #[ from] ChunkStorageError ) ,
87- #[ error( "Failed to read chunk element from stream/iterator: {source} " ) ]
90+ #[ error( "Failed to read chunk element from stream/iterator" ) ]
8891 ChunkContentsEvalError {
8992 submission_prefix : Box < str > ,
9093 chunk_type : ChunkType ,
94+ #[ source]
9195 source : anyhow:: Error ,
9296 } ,
9397}
9498
9599#[ derive( thiserror:: Error , Debug ) ]
96100pub enum NewObjectStoreClientError {
97- #[ error( "Failed to parse URL: {0} " ) ]
101+ #[ error( "Failed to parse URL" ) ]
98102 UrlParseFailure ( #[ from] url:: ParseError ) ,
99- #[ error( "URL is not valid object store URL {0} " ) ]
103+ #[ error( "URL is not valid object store URL" ) ]
100104 ObjectStoreUrlFailure ( #[ from] object_store:: Error ) ,
101105}
102106
0 commit comments