C2 failure on rust-fil-proofs test
Closed this issue · 3 comments
In my SupraSeal C2 integration work for rust-fil-proofs
I ran into a failing test, it sefaults. Here are the steps to reproduce:
git clone https://github.com/filecoin-project/rust-fil-proofs --branch sn-c2
cd rust-fil-proofs
RUST_LOG=trace cargo test --no-default-features --features supraseal --package filecoin-proofs --test api test_window_post_partition_matching_2kib_base_8 -- --nocapture --test-threads=1
It works when run with e.g. OpenCL RUST_LOG=trace cargo test --no-default-features --features opencl --package filecoin-proofs --test api test_window_post_partition_matching_2kib_base_8 -- --nocapture --test-threads=1
This is another case of the SRS file not being read before the proof.
"/var/tmp/filecoin-proof-parameters/v28-proof-of-spacetime-fallback-merkletree-poseidon_hasher-8-0-0-0170db1f394b35d995252228ee359194b13199d259380541dc529fb0099096b0.params"
is the SRS file that's being used on my end, and reading that with supraseal_c2::read_srs(String::from("..."));
somewhere before the proof fixes the issue and tests pass.
Good catch, sorry for the noise. I need to make sure that reading in the parameters is always in the code path, even for tests.
I guess as mentioned in the other isssue, an error message would help :)
No problem.
We will have an update soon where we will make it so that read_srs
will return a pointer, wrapped with a Rust struct, which will get passed on to the C++ side, like we discussed. Then it will be impossible to run into this issue.