Skip to content

Commit 0110532

Browse files
authored
Merge of #2077
2 parents a3fd447 + 9c8a42a commit 0110532

File tree

1 file changed

+10
-13
lines changed

1 file changed

+10
-13
lines changed

coprocessor/fhevm-engine/gw-listener/src/gw_listener.rs

Lines changed: 10 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -201,19 +201,16 @@ impl<P: Provider<Ethereum> + Clone + 'static, A: AwsS3Interface + Clone + 'stati
201201
continue;
202202
}
203203
if let Ok(event) = InputVerification::InputVerificationEvents::decode_log(&log.inner) {
204-
match event.data {
205-
InputVerification::InputVerificationEvents::VerifyProofRequest(request) => {
206-
self.verify_proof_request(db_pool, request, log.clone()).await.
207-
inspect(|_| {
208-
verify_proof_success += 1;
209-
}).inspect_err(|e| {
210-
error!(error = %e, "VerifyProofRequest processing failed");
211-
VERIFY_PROOF_FAIL_COUNTER.inc();
212-
})?;
213-
},
214-
_ => {
215-
error!(log = ?log, "Unknown InputVerification event");
216-
}
204+
// This listener only reacts to proof requests. Other known InputVerification
205+
// events are expected when multiple coprocessors interact with the gateway.
206+
if let InputVerification::InputVerificationEvents::VerifyProofRequest(request) = event.data {
207+
self.verify_proof_request(db_pool, request, log.clone()).await.
208+
inspect(|_| {
209+
verify_proof_success += 1;
210+
}).inspect_err(|e| {
211+
error!(error = %e, "VerifyProofRequest processing failed");
212+
VERIFY_PROOF_FAIL_COUNTER.inc();
213+
})?;
217214
}
218215
} else {
219216
error!(log = ?log, "Failed to decode InputVerification event log");

0 commit comments

Comments
 (0)