-
Notifications
You must be signed in to change notification settings - Fork 666
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
Yield Execution (NEP 516 / NEP 519) #10455
Comments
can we link PRs for listed tasks to this tracking issue? |
I have a couple of draft PRs I'm continuing to iterate on:
I don't anticipate having separate PRs for each subtask since it won't make sense to merge this until we have all the details right. |
Here some thoughts I had over today as I was thinking about estimation and costs for this feature.
|
I have addressed the concern of the data being read out multiple times throughout the life of an unresolved promise in the PR referenced just above. Now we only are going to do a simple check for key existence, which simplifies the cost model significantly. In particular the model now does not need to account for the period of time between when the In my mind a correct cost model in context of these changes looks like this:
|
|
Status update @walnut-the-cat: Fixed-length timeouts are implemented now. Work continues on gas costs and bounding congestion (mainly thanks @nagisa), as well as on the misc. smaller implementation details documented on this tracking issue. |
Very excited about this idea! Thank you, contributors |
NEPs: near/NEPs#516 near/NEPs#519
The following branches contain a basic prototype of yield execution supporting the chain signatures use case:
To test out the chain signatures contract:
neard
and run localnet.mpc_contract
fromnear-sdk-rs/examples
.mpc.node0
on localnet:env NEAR_ENV=localnet near create-account "mpc.node0" --keyPath ~/.near/localnet/node0/validator_key.json --masterAccount node0
.requester.node0
andsigner.node0
.env NEAR_ENV=localnet near deploy "mpc.node0" <path/to/mpc_contract.wasm>
env NEAR_ENV=localnet near call mpc.node0 sign '{"payload" : "foo"}' --accountId requester.node0
. Observe that the request will hang.env NEAR_ENV=localnet near call mpc.node0 log_pending_requests --accountId signer.node0
to see the data id for the pending request. In a real use case, the signer node will monitor the contract via indexers to get this information.env NEAR_ENV=localnet near call mpc.node0 sign_respond '{"data_id":"<data id here>","signature": "sig_of_foo"}' --accountId signer.node0
Note that steps 6-8 are a bit time-sensitive at the moment. If the call to
sign
in step 6 doesn't receive a response from step 8 within roughly a minute, you'll eventually see a messageRetrying transaction due to expired block hash
.Remaining work includes:
Tasks
The text was updated successfully, but these errors were encountered: