-
Notifications
You must be signed in to change notification settings - Fork 0
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
ZSA bundle enum #78
base: zsa1
Are you sure you want to change the base?
ZSA bundle enum #78
Conversation
PR-Agent was enabled for this repository. To continue using it, please link your git user with your CodiumAI identity here. PR Reviewer Guide 🔍Here are some key observations to aid the review process:
|
PR-Agent was enabled for this repository. To continue using it, please link your git user with your CodiumAI identity here. PR Code Suggestions ✨Explore these optional code suggestions:
|
dfb4fe8
to
1c6529c
Compare
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.
please update the branches (especially Orchard with regard to QED-it/orchard#119)
Cargo.toml
Outdated
@@ -58,7 +58,7 @@ sapling = { package = "sapling-crypto", version = "0.1.3" } | |||
|
|||
# - Orchard | |||
nonempty = "0.7" | |||
orchard = { version = "0.8.0", default-features = false, git = "https://github.com/QED-it/orchard", branch = "zsa1" } | |||
orchard = { version = "0.8.0", default-features = false, git = "https://github.com/QED-it/orchard", branch = "spendauth_clone" } |
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.
we need the related PR
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.
Done, there is an open PR in Orchard
QED-it/orchard#125
.github/workflows/ci.yml
Outdated
# strategy: | ||
# matrix: | ||
# target: | ||
# - wasm32-wasi |
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.
why?
It worked this far: https://github.com/QED-it/librustzcash/actions/runs/11270263928/job/31340598915
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.
I've brought it back, let's see
Cargo.toml
Outdated
@@ -127,4 +127,4 @@ codegen-units = 1 | |||
[patch.crates-io] | |||
zcash_note_encryption = { version = "0.4", git = "https://github.com/QED-it/zcash_note_encryption", branch = "zsa1" } | |||
sapling = { package = "sapling-crypto", version = "0.1.3", git = "https://github.com/QED-it/sapling-crypto", branch = "zsa1" } | |||
orchard = { version = "0.8.0", git = "https://github.com/QED-it/orchard", branch = "zsa1" } | |||
orchard = { version = "0.8.0", default-features = false, git = "https://github.com/QED-it/orchard", branch = "spendauth_clone" } |
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.
I don't follow, shouldn't we use the branch from QED-it/orchard#119 ?
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.
It is based on the one you mention
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.
the one i mentioned is remove_circuit_param. But I prefer zsa1
and a commit hash
&self.orchard_saks, | ||
) | ||
}) | ||
.unwrap(), |
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.
do not ignore the possibility of error here: (x2)
let orchard_bundle: Option<OrchardBundle<_>> = match unauthed_tx.orchard_bundle {
Some(OrchardBundle::OrchardVanilla(b)) => {
Some(OrchardBundle::OrchardVanilla(Box::new(
b.create_proof(
&orchard::circuit::ProvingKey::build::<OrchardVanilla>(),
&mut rng,
)
.and_then(|b| {
b.apply_signatures(
&mut rng,
*shielded_sig_commitment.as_ref(),
&self.orchard_saks,
)
})
.map_err(Error::OrchardBuild)?,
)))
}
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.
Done
This reverts commit f33189f.
7bac6f1
to
387c5d8
Compare
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.
This looks much better! waiting for the test vectors.
User description
Replace 2 separate Orchard bundle with a single enum
PR Type
enhancement
Description
OrchardBundle
enum to consolidate the handling of Orchard bundles, replacing separate variables for different bundle types.BuildBundle
trait for constructingOrchardVanilla
andOrchardZSA
bundles.OrchardBundle
enum, simplifying the code and removing redundancy.orchard
dependency branch inCargo.toml
tospendauth_clone
.Changes walkthrough 📝
builder.rs
Consolidate Orchard bundle handling with `OrchardBundle` enum
zcash_primitives/src/transaction/builder.rs
OrchardBundle
enum.
OrchardBundle
enum types.unproven_orchard_zsa_bundle
variable.orchard.rs
Implement `BuildBundle` trait and update bundle handling
zcash_primitives/src/transaction/components/orchard.rs
BuildBundle
trait for constructing bundles.BuildBundle
forOrchardVanilla
andOrchardZSA
.OrchardBundle
.mod.rs
Unify Orchard bundle handling with `OrchardBundle` enum
zcash_primitives/src/transaction/mod.rs
OrchardBundle
enum to unify bundle handling.OrchardBundle
.OrchardZSA
bundles.txid.rs
Update transaction digest logic for `OrchardBundle`
zcash_primitives/src/transaction/txid.rs
OrchardBundle
.OrchardZSA
.tests.rs
Update tests for unified `OrchardBundle` handling
zcash_primitives/src/transaction/tests.rs
OrchardBundle
handling.OrchardZSA
.Cargo.toml
Update `orchard` dependency branch
Cargo.toml
orchard
dependency branch tospendauth_clone
.