-
Notifications
You must be signed in to change notification settings - Fork 0
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
feat: allow list solver flag #48
base: main
Are you sure you want to change the base?
Conversation
SolverNetwork model has an active flag that should be the only one
@@ -41,6 +41,11 @@ | |||
"type": "relation", | |||
"relation": "oneToOne", | |||
"target": "api::environment.environment" | |||
}, | |||
"allowListed": { |
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.
fine with me, but for me is more clear to just say "isOperating".
Also, renaming active to isWhiteListed
could be a good idea. We can just add the flag, make sure they match, make the changes in CoW Swap, and then delete the old flag. I don't see anyone else uses this (maybe my spreadsheet and I can adapt it)
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.
The point about adding a new flag is that, at least from what I could gather from the solver's team view, it has a different connotation that what we need for the progress bar.
They set it to active when the solver has been allow-listed, even if the solver is not running for that environment.
Thus, the new flag is meant to signal that, while active remains what we expect: the solver is enabled and solving for the given network/environment.
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.
Well, I understood the other way around. Active was that our protocol whitelisted them, although I see why it makes sense too what you say.
This is why I was suggesting to not leave "active" to avoid confusion.
isWhiteListed
--> whitelitest in the protocol.
isOperating
---> is running an instance and posting solutions
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.
maybe there's better names, but just think that "active" might be confusing
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.
Alternativelly, we don't use flags, and we just model the status: WHITE_LISTED_INACTIVE, WHITE_ACTIVE, NOT_WHITE_LISTED
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.
This is why I was suggesting to not leave "active" to avoid confusion.
Ah got it.
Alternativelly, we don't use flags, and we just model the status
I don't get this one. Would that be a new entity?
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.
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.
but probably not a good idea, and we want to separate the 2 concerns. I imagine that if this is automatically managed, the whitelisted flag is set manually, but the active is set automatically (for example, solver hasn't posted a solution in 24h)
Summary
2 changes:
allowListed
to SolverNetwork modelUse this to indicate whether the given solver has been allow-listed for this network/env.
active
from Solver modelSolverNetwork also has an
active
flag that's used to indicate whether given solver is active for network/env.This flag is a n artifact of a previous iteration of the model and should be removed.