-
Notifications
You must be signed in to change notification settings - Fork 212
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 'onCondition' exit rule support into Zoe #3657
Comments
@zarutian, can you give a few user stories about how this would be used? |
One userstory that comes to mind is that the user and the contract deployer do not want to fully relie on only one TimerService so the ConditionChecker (which they can relie on) gets a condition expr that amounts to 'either A OR B' have expired. Another is where the user might want a recourse in the case of long expiry to exit sooner iff three fourths of klehios like arbitrators agree. Yet another is where the seat can be exited only iff another spefic smart contract has signalled something. It might be a governence vote concluded or such. Is this sufficient amount of coarsely painted user stories or do you want more? |
Thanks @zarutian! This sounds like a very helpful idea. I'll add this to our backlog of features to consider. |
What is the Problem Being Solved?
currently Zoe seats have only three kinds of exit rules:
Description of the Design
I propose the exit rule 'onCondition' that looks similiar to 'onExpiry'.
The parameters of the rule would have a ConditionChecker and a Condition (perhaps expressed in slightly extended jsonlogic but zoe treats it as if it were opaque)
When UserSeat holder does .tryExit(), zoe does
to see if the seat can be exited by the UserSeat holder or not.
Security Considerations
Same kind as with ERTP Issuers and TimerServices, the ConditionChecker being maliciously slow or non-responsive.
Test Plan
TBD
The text was updated successfully, but these errors were encountered: