Skip to content

Commit

Permalink
Revert added context on funrun errors (#23734)
Browse files Browse the repository at this point in the history
This seems to overwrite the existing message, which isn't what we want. Reverting for now.

GitOrigin-RevId: 9b9963f2bfc1c53e9100369f0cda7983b44d3b64
  • Loading branch information
sshader authored and Convex, Inc. committed Mar 20, 2024
1 parent 70ec185 commit 3292468
Showing 1 changed file with 0 additions and 13 deletions.
13 changes: 0 additions & 13 deletions crates/pb/src/error_metadata.rs
Original file line number Diff line number Diff line change
@@ -1,5 +1,3 @@
use std::fmt::Display;

use anyhow::Context;
use errors::{
ErrorCode,
Expand Down Expand Up @@ -81,9 +79,6 @@ impl TryFrom<ErrorMetadataProto> for ErrorMetadata {
pub trait ErrorMetadataStatusExt {
fn from_anyhow(error: anyhow::Error) -> Self;
fn into_anyhow(self) -> anyhow::Error;
fn context<C>(self, context: C) -> Self
where
C: Display + Send + Sync + 'static;
}

impl ErrorMetadataStatusExt for tonic::Status {
Expand Down Expand Up @@ -117,14 +112,6 @@ impl ErrorMetadataStatusExt for tonic::Status {
}
error
}

fn context<C>(self, context: C) -> Self
where
C: Display + Send + Sync + 'static,
{
let anyhow_err = self.into_anyhow();
Self::from_anyhow(anyhow_err.context(context))
}
}

#[cfg(test)]
Expand Down

0 comments on commit 3292468

Please sign in to comment.