-
Notifications
You must be signed in to change notification settings - Fork 74
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add objective
Flag And use SuplusFeesCosts
for Price Estimates
#229
Conversation
The parameter is called |
Oops 🙈 - fixed. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Shouldn't it better be objective
in all places where you wrote optimize
or OptimizeFor
?
@@ -38,7 +38,7 @@ use shared::{ | |||
}, | |||
baseline_solver::BaseTokens, | |||
current_block::current_block_stream, | |||
http_solver::{DefaultHttpSolverApi, SolverConfig}, | |||
http_solver::{DefaultHttpSolverApi, Objective, SolverConfig}, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Is this change needed here, or is the new parameter part of SolverConfig
?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Its a new parameter part of SOlverConfig
.
Driver creates one with default objective (so nothing specified in the query URL) for solving batches and the orderbook creates on with objective set to surplusfeescosts
for price estimates.
Sorry @twalth3r, so many brain-farts. Hopefully should be correct now. |
optimize
Flag And use SuplusFeesCosts
for Price Estimatesobjective
Flag And use SuplusFeesCosts
for Price Estimates
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks good to me now - thanks @nlordell !
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Nice. Lgtm
This PR adds a new field to
SolverConfig
to allow configuring Quasimodo for different environments. Specifically, requests to Quasimodo from the solver should use a different objective then when requesting price estimates (when solving, Quasimodo defaults to optimizing with capped surplus, which we don't want for price estimates).Test Plan
Run the orderbook locally and see the new parameter: