chore: add .attach_printable for InternalServerError (#368)

This commit is contained in:
Nishant Joshi
2023-01-17 17:23:57 +05:30
committed by GitHub
parent fb8d67a9f3
commit be9889b47a
14 changed files with 178 additions and 48 deletions

View File

@ -467,7 +467,8 @@ where
)
.await
.into_report()
.change_context(errors::ApiErrorResponse::InternalServerError)?;
.change_context(errors::ApiErrorResponse::InternalServerError)
.attach_printable("Failed while getting process schedule time")?;
match schedule_time {
Some(stime) => {
@ -476,6 +477,7 @@ where
.await
.into_report()
.change_context(errors::ApiErrorResponse::InternalServerError)
.attach_printable("Failed while adding task to process tracker")
}
None => Ok(()),
}