Skip to content

Commit

Permalink
[TRIVIAL] Add implementation detail reminder for the settlement queue (
Browse files Browse the repository at this point in the history
…#3240)

~~Seems like it was overlooked in
#3129. `/solve` requests
must not be sent in case the settlement queue for the current solver is
out of capacity.~~ Adds a comment as a reminder that the queue needs to
be checked only **after** the solve response is received.
  • Loading branch information
squadgazzz authored Jan 17, 2025
1 parent df6306c commit a6b8f42
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions crates/driver/src/infra/api/routes/solve/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -37,6 +37,8 @@ async fn route(
.prioritize(auction, &competition.solver.account().address())
.await;
let result = competition.solve(auction).await;
// Solving takes some time, so there is a chance for the settlement queue to
// have capacity again.
competition.ensure_settle_queue_capacity()?;
observe::solved(state.solver().name(), &result);
Ok(axum::Json(dto::SolveResponse::new(
Expand Down

0 comments on commit a6b8f42

Please sign in to comment.