You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I'm getting the following error while trying to run cargo run --release -- pbrt_ganesha/ganesha.pbrt:
thread 'main' panicked at 'attempted to leave type `linked_hash_map::Node<std::string::String, ply_rs::ply::ElementDef>` uninitialized, which is invalid', /rustc/2fd73fabe469357a12c2c974c140f67e7cdd76d0/library/core/src/mem/mod.rs:671:9
stack backtrace:
0: rust_begin_unwind
at /rustc/2fd73fabe469357a12c2c974c140f67e7cdd76d0/library/std/src/panicking.rs:493:5
1: core::panicking::panic_fmt
at /rustc/2fd73fabe469357a12c2c974c140f67e7cdd76d0/library/core/src/panicking.rs:92:14
2: core::panicking::panic
at /rustc/2fd73fabe469357a12c2c974c140f67e7cdd76d0/library/core/src/panicking.rs:50:5
3: <linked_hash_map::LinkedHashMap<alloc::string::String,V> as ply_rs::ply::key_map::Addable<V>>::add
4: rs_pbrt::shapes::plymesh::create_ply_mesh
5: rs_pbrt::core::api::get_shapes_and_materials
6: rs_pbrt::core::api::pbrt_shape
7: rs_pbrt::parse_line
8: rs_pbrt::parse_file
9: rs_pbrt::main
This problem is caused by Undefined Behaviour in versions 0.5.3 and below of linked-hash-map: contain-rs/linked-hash-map#106 which is imported via ply-rs.
I have a PR up for ply-rs that fixes this issue: Fluci/ply-rs#18 so for now setting ply-rs in Cargo.toml to ply-rs = { git = "https://github.com/expenses/ply-rs", branch = "linked-hash-map-bump" } works.
It seems like ply-rs hasn't been updated for a while so it's up to you whether you want to wait for it to update or to fix this in a different way.
The text was updated successfully, but these errors were encountered:
Hi @expenses ,
Thanks for reporting this. I just confirmed your reported problem and the fix you suggest seems to work.
Maybe I wait a bit if the PR gets accepted and a new release of ply-rs will be created.
Thanks, again
could you try with the latest commits, please? For me the ganesha.pbrt scene seems to work now. Because I do not ship example scenes with the Rust crate anymore you might have to clone this repository:
I'm getting the following error while trying to run
cargo run --release -- pbrt_ganesha/ganesha.pbrt
:This problem is caused by Undefined Behaviour in versions
0.5.3
and below oflinked-hash-map
: contain-rs/linked-hash-map#106 which is imported viaply-rs
.I have a PR up for
ply-rs
that fixes this issue: Fluci/ply-rs#18 so for now settingply-rs
inCargo.toml
toply-rs = { git = "https://github.com/expenses/ply-rs", branch = "linked-hash-map-bump" }
works.It seems like
ply-rs
hasn't been updated for a while so it's up to you whether you want to wait for it to update or to fix this in a different way.The text was updated successfully, but these errors were encountered: