Skip to content

Commit

Permalink
fix: do not leak inputs on error (#1228)
Browse files Browse the repository at this point in the history
Close #1225
  • Loading branch information
OlivierDehaene authored Nov 20, 2023
1 parent 8acdc1f commit 3dbc649
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
6 changes: 3 additions & 3 deletions router/src/infer.rs
Original file line number Diff line number Diff line change
Expand Up @@ -82,7 +82,7 @@ impl Infer {
}

/// Add a new request to the queue and return a stream of InferStreamResponse
#[instrument(skip(self))]
#[instrument(skip_all)]
pub(crate) async fn generate_stream(
&self,
request: GenerateRequest,
Expand Down Expand Up @@ -133,7 +133,7 @@ impl Infer {
}

/// Add a new request to the queue and return a InferResponse
#[instrument(skip(self))]
#[instrument(skip_all)]
pub(crate) async fn generate(
&self,
request: GenerateRequest,
Expand Down Expand Up @@ -214,7 +214,7 @@ impl Infer {
}
/// Add best_of new requests to the queue and return a InferResponse of the sequence with
/// the highest log probability per token
#[instrument(skip(self))]
#[instrument(skip(self, request))]
pub(crate) async fn generate_best_of(
&self,
request: GenerateRequest,
Expand Down
2 changes: 1 addition & 1 deletion router/src/validation.rs
Original file line number Diff line number Diff line change
Expand Up @@ -69,7 +69,7 @@ impl Validation {
}
}

#[instrument(skip_all)]
#[instrument(skip(self, inputs))]
async fn validate_input(
&self,
inputs: String,
Expand Down

0 comments on commit 3dbc649

Please sign in to comment.