-
Notifications
You must be signed in to change notification settings - Fork 94
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
[r2r] Allow passing Zcash params file path to activation request #1538
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.
Thanks for the PR! One note.
mm2src/coins/z_coin.rs
Outdated
let (spend_path, output_path) = if path.exists() { | ||
(path.join(SAPLING_SPEND_NAME), path.join(SAPLING_OUTPUT_NAME)) | ||
} else { | ||
return MmError::err(ZCoinBuildError::ZCashParamsNotFound); | ||
}; | ||
if !(spend_path.exists() && output_path.exists()) { | ||
return MmError::err(ZCoinBuildError::ZCashParamsNotFound); | ||
} | ||
LocalTxProver::new(&spend_path, &output_path) |
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.
As there are FS operations and LocalTxProver::new
can take significant time to load, please wrap this entire code block into async_blocking
.
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, I see.
Done
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.
Thanks :) |
related to ARRR integration. #927
Now we can pass
zcash_params_path
parameter to Zcoin activation request.curl example with path param:
The tree example for easy reading looks like:
Without the path parameter the
default
path will be used, which is home directory plus the name of zcash params folder in current OS. Like it was before this PR.