-
Notifications
You must be signed in to change notification settings - Fork 19
refactor/fix: contract objects take two separate providers for reads and writes #110
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
Conversation
86a9790
to
b930f5b
Compare
0ea5f09
to
72aa2c4
Compare
72aa2c4
to
b9a1c89
Compare
|
} | ||
} | ||
|
||
#[tracing::instrument(err)] |
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.
Implementing here will respect specialized impl
write_contract: Arc::new(EthereumHomeInternal::new( | ||
address.as_ethereum_address().expect("!eth address"), | ||
provider.clone(), | ||
write_provider, |
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.
use contract.connect
to clone with a different provider
https://docs.rs/ethers/latest/ethers/contract/struct.Contract.html#method.connect
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.
} | ||
|
||
#[tracing::instrument(err)] | ||
async fn prove_and_process( |
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.
was this simply moved? if so, why? if not, what changes were made?
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.
Moving to struct impl should fix the problem of the default impl being called (prove then process instead of proveAndProcess)
3ad18ee
to
db607dd
Compare
Dispatch
events