-
Notifications
You must be signed in to change notification settings - Fork 382
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
OVMi Part2 AtomicPredicates #154
Conversation
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.
LGTM
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, I just have one question around external call structure lifetime, is it really needed? Could you check it in comments please.
ovmi/lib/src/predicates/equal.rs
Outdated
|
||
impl<'a, Ext: ExternalCall> AtomicPredicateInterface<AddressOf<Ext>> for EqualPredicate<'a, Ext> { | ||
fn decide(&self, inputs: Vec<Vec<u8>>) -> ExecResult<AddressOf<Ext>> { | ||
println!( |
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.
Better use log::debug
here.
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.
oh..
That's a mistake to remove.
use crate::Range; | ||
|
||
pub struct IsLessThanPredicate<'a, Ext: ExternalCall> { | ||
pub ext: &'a Ext, |
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.
What's about to use Arc
here instead of a specified lifetime? In my view 'a
makes interface a bit dirty.
use crate::Range; | ||
|
||
pub struct IsValidSignaturePredicate<'a, Ext: ExternalCall> { | ||
pub ext: &'a Ext, |
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.
Here too.
@akru Please let me know if you have any problems. |
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.
LGTM
* Dusty chainspec upgrade (#155) * Plasm Network mainnet (#149) * Plasm Network mainnet genesis * Bump frame modules * Added mainnet genesis into subkey * Added bootnodes * Bump version in README * Create feature_task.md (#150) * Create feature_task.md * Rename feature_task.md to future_task.md * Update future_task.md * Update feature_request.md * Update feature_request.md * Update future_task.md * Update chainspec: dusty2 * fix fmt Co-authored-by: satellitex <[email protected]> * update reward functionality * apply formatting * use mutate * separate claim into two methods * modify tests * fix overflow * check if era is valid * add doc comments * OVMi Part2 AtomicPredicates (#154) * WIP: or decidable * add or * ovm ext_call is not needed mut * add all logical and deciable predicates * WIP: eq * add AtomicPredicates * fmt and add lock * add from_address to executable predicate * add predicate mock * fmt * add tests * add from_address to executable predicate * upd lock * tmp * fix name * WIP: is valid signature * lifetime * fix lifetime 2 * add staking amounts for each operator * Plasm lockdrop oracle requests refactoring (#158) * Using localhost oracle for lockdrop module * Added small https proxy helper * Disable lockdrop oracle by default * Fix fmt * Add claim into subkey (#164) * add claim into subkey g * use inspect * fix use v * reverse use plasm * Plasma module Part1 (#162) * WIP: plasma module * build passed template * add submit root * add deploy and first test * success submit_root test * passed build commitment * add rpc call for plasma * fix for plasm hashing * add describe plapps_hash * Upgrade Plasm Node up to substrate 2.0-rc2 (#170) * Upgrade to substrate 2.0-rc2 * Fix unused imports * enable dapps staking * Feature plasma deposit (#171) * add deposit * passed build * add finalize_checkpoint * WIP: bare_finalize_exit * WIP deserializer * WIP: add modules * WIP * pssed build * WIP: fix weight * fix ovm and plasma * passed deposit test * WIP: plasm-deposit * WIP fix range * passed until xxx * assed without finalized * fix passed test * fix docker builder (#176) * Dusty release 1.1.0 (#174) * Bump version, fix chain specs * Added legacy storage runtime interface * Using default child for legacy calls * Fix compilation & format * Bump subkey version * [CI]: bump nix actions version * Fix implementation name Co-authored-by: satellitex <[email protected]> Co-authored-by: t8m8 <[email protected]>
#153
Implement about
BaseAtomicPredicates
.without using signature.(
verify_inclusion
andis_valid_sginature
)Dependencies
Signatures are handled in a separate PR, as there is a dependency PR here.
paritytech/substrate#6029
Checklist
Affected core subsystem(s)
Description of change