fix: do not leak inputs on error (#1228)

Close #1225
This commit is contained in:
OlivierDehaene 2023-11-20 10:33:44 +01:00 committed by GitHub
parent 8acdc1fae7
commit 3dbc649b11
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 4 additions and 4 deletions

View File

@ -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,
@ -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,
@ -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,

View File

@ -69,7 +69,7 @@ impl Validation {
}
}
#[instrument(skip_all)]
#[instrument(skip(self, inputs))]
async fn validate_input(
&self,
inputs: String,