Open omershlo opened 4 years ago
happening to me too on MacOS 10.14.6
(PARI installed using homebrew
). Have enabled parisizemax
in .gprc but didn't help.
thanks for reporting
I got two reports for users that on their machines the problem did not occur. I will get more details on their setups. They suggested to consult : http://pari.math.u-bordeaux.fr/pub/pari/manuals/2.11.1/libpari.pdf page 17
here are the setups that report of NO error: 1) Ubuntu 19.04, with rustc 1.39.0-nightly, gp/pari 2.11.1. I ran 60 times the cargo test --features=cclst without errors.
2) macOS Mojave 10.14.6 and installed rust in a virtualbox 6.0.10 r132072 with debian stable 10.1, rustc 1.39.0-nightly
I setup a fresh Ubuntu 19.04 on Digital Ocean with apt-get install build-essential llvm clang
, installed with rustup nightly and still not working. I got a
process didn't exit successfully: `/root/multi-party-ecdsa/target/debug/build/class_group-2cc3d835d71af03f/build-script-build` (exit code: 101)
--- stderr
wrapper.h:2:10: fatal error: 'pari/pari.h' file not found
wrapper.h:2:10: fatal error: 'pari/pari.h' file not found, err: true
thread 'main' panicked at 'Unable to generate bindings: ()', src/libcore/result.rs:1165:5
Then tried to install PARI via apt-get install pari-gp2c
and it build but got a different error:
root@ubuntu-s-2vcpu-2gb-lon1-01:~/multi-party-ecdsa# RUST_BACKTRACE=1 cargo test --features=cclst
Compiling class_group v0.1.4 (https://github.com/KZen-networks/class-groups?tag=v0.1.4#4501c2b8)
Compiling multi-party-ecdsa v0.2.3 (/root/multi-party-ecdsa)
error[E0308]: mismatched types
--> src/protocols/two_party_ecdsa/cclst_2019/party_one.rs:278:13
|
278 | GE::generator() * &party_one_private.x1,
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ expected struct `curv::elliptic::curves::secp256_k1::Secp256k1Point`, found a different struct `curv::elliptic::curves::secp256_k1::Secp256k1Point`
|
= note: expected type `curv::elliptic::curves::secp256_k1::Secp256k1Point` (struct `curv::elliptic::curves::secp256_k1::Secp256k1Point`)
found type `curv::elliptic::curves::secp256_k1::Secp256k1Point` (struct `curv::elliptic::curves::secp256_k1::Secp256k1Point`)
note: Perhaps two different versions of crate `curv` are being used?
--> src/protocols/two_party_ecdsa/cclst_2019/party_one.rs:278:13
|
278 | GE::generator() * &party_one_private.x1,
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
error: aborting due to previous error
🤷♂️
@trepca the error you got was my fault. I fixed this error and now it should work. Please confirm
I check the idea of @amanusk from https://github.com/KZen-networks/class-groups/issues/20 .
It appears that running single thread all the tests solves the problem:
cargo test --features=cclst -- --test-threads=1
We do need to find a way to run Pari in parallel
great, that works, even natively on MacOS
While running
protocols::two_party_ecdsa::cclst_2019::test::tests::test_two_party_sign
orprotocols::two_party_ecdsa::cclst_2019::test::tests::test_full_key_gen
is always working and passing. Trying to justcargo test --features=cclst
returns a PARI error. Each time a different one:It can sometimes work, while other times the following errors are received:
Might be connected to
pari_init
in class_groups lib