Skip to content

Conversation

@Ansonhkg
Copy link
Collaborator

@Ansonhkg Ansonhkg commented Aug 21, 2025

WHAT

A fix for the following error, as it's pulling in multiexp 0.4.2 which has a breaking change.

In the Cargo.lock we should revert it to 0.4.0

[[package]]
name = "multiexp"
version = "0.4.0"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "25a383da1ae933078ddb1e4141f1dd617b512b4183779d6977e6451b0e644806"
dependencies = [
 "ff",
 "group",
 "rustversion",
 "std-shims",
 "zeroize",
]

ERROR

error[E0277]: the trait bound `G: Zeroize` is not satisfied
   --> /home/runner/.cargo/registry/src/index.crates.io-6f17d22bba15001f/elliptic-curve-tools-0.1.2/src/sum_of_products.rs:19:30
    |
19  |         multiexp::multiexp::<Self>(pairs)
    |                              ^^^^ the trait `DefaultIsZeroes` is not implemented for `G`, which is required by `G: Zeroize`
    |
    = note: required for `G` to implement `Zeroize`
note: required by a bound in `multiexp`
   --> /home/runner/.cargo/registry/src/index.crates.io-6f17d22bba15001f/multiexp-0.4.2/src/lib.rs:180:20
    |
180 | pub fn multiexp<G: Zeroize + Group>(pairs: &[(G::Scalar, G)]) -> G
    |                    ^^^^^^^ required by this bound in `multiexp`
help: consider further restricting this bound
    |
15  |     G: Group + zeroize::DefaultIsZeroes,
    |              ++++++++++++++++++++++++++

   Compiling bls12_381_plus v0.8.18
For more information about this error, try `rustc --explain E0277`.
error: could not compile `elliptic-curve-tools` (lib) due to 1 previous error
warning: build failed, waiting for other jobs to finish...
Error: Compiling your crate to WebAssembly failed
Caused by: Compiling your crate to WebAssembly failed
Caused by: failed to execute `cargo build`: exited with exit status: 101
  full command: cd "./rust" && "cargo" "build" "--lib" "--release" "--target" "wasm32-unknown-unknown"
npm error Lifecycle script `rust:build` failed with error:
npm error code 1
npm error path /home/runner/work/js-sdk/js-sdk/packages/wasm
npm error workspace @lit-protocol/[email protected]
npm error location /home/runner/work/js-sdk/js-sdk/packages/wasm
npm error command failed
npm error command sh -c wasm-pack build ./rust --target web --release --out-name wasm-internal && yarn rust:postbuild

@Ansonhkg Ansonhkg self-assigned this Aug 21, 2025
@Ansonhkg Ansonhkg added 🐞 Bug Fix Something isn't working v8 | Naga labels Aug 21, 2025
@Ansonhkg Ansonhkg merged commit a090098 into naga Aug 21, 2025
3 checks passed
@Ansonhkg Ansonhkg deleted the fix/cargo-lock branch August 21, 2025 12:45
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

🐞 Bug Fix Something isn't working v8 | Naga

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants