diff --git a/Cargo.toml b/Cargo.toml index e00ba93..adf0f67 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -35,8 +35,8 @@ serde = { version = "1", features = ["derive"] } serde_json = { version = "1", features = ["float_roundtrip"] } log = "0.4" -# 3MF packages (docs/formats/tagged-mesh.md). -zip = { version = "3", default-features = false, features = ["deflate"] } +# 3MF packages (docs/formats/tagged-mesh.md). zip is ahead of SolidCraft (still on 3), so both are built. +zip = { version = "9", default-features = false, features = ["deflate"] } quick-xml = "0.42" # content hashes and part checksums of .fieldcraft files (the version SolidCraft uses) diff --git a/crates/geometry/src/tagged_mesh.rs b/crates/geometry/src/tagged_mesh.rs index 98a4f5a..20e1b89 100644 --- a/crates/geometry/src/tagged_mesh.rs +++ b/crates/geometry/src/tagged_mesh.rs @@ -446,7 +446,7 @@ mod tests { for (name, data) in [("[Content_Types].xml", types), ("_rels/.rels", rels), ("3D/3dmodel.model", x.as_str())] { let o = zip::write::SimpleFileOptions::default() .compression_method(zip::CompressionMethod::Deflated) - .last_modified_time(zip::DateTime::default()); + .last_modified_time(Some(zip::DateTime::default())); zip.start_file(name, o).unwrap(); zip.write_all(data.as_bytes()).unwrap(); } diff --git a/crates/io/src/lib.rs b/crates/io/src/lib.rs index fdee8c7..044bb94 100644 --- a/crates/io/src/lib.rs +++ b/crates/io/src/lib.rs @@ -335,7 +335,7 @@ pub fn write(model: &Model, geometry: &Geometry, journal: &[JournalEntry], view: // Fixed time and permissions: the bytes depend on the model only. let options = zip::write::SimpleFileOptions::default() .compression_method(zip::CompressionMethod::Stored) - .last_modified_time(zip::DateTime::default()) + .last_modified_time(Some(zip::DateTime::default())) .unix_permissions(0o644) .large_file(bytes.len() as u64 >= u64::from(u32::MAX)); zip.start_file(name, options).map_err(zip_error)?;