From 2216f71ca9f9ad730a95c693483fdbde17889476 Mon Sep 17 00:00:00 2001 From: sylph-pi Date: Mon, 7 Sep 2026 21:06:26 +0200 Subject: [PATCH] fix(formats): drop the unused normal `tokio` dependency `sylpheed-formats` declared `tokio` as a normal dependency and never used it as one. All four references in its `src/` are inside a `mod tests` -- three runtime builders in ship.rs (539, 566, 690; `mod tests` at 498) and one `#[tokio::test]` in xiso.rs (182; `mod tests` at 179) -- and tokio was ALREADY present in `[dev-dependencies]`, so the tests keep compiling unchanged. The unused normal dependency pulled `tokio/full`, whose `net` feature drags in `mio`, which does not build for wasm32: error: This wasm target is unsupported by mio. Removing it is right on its own terms; the WASM job is merely what exposed it. Native is unaffected -- `cargo check --workspace` exits 0 on x86_64. This is separated from the CI configuration it was found through because it is the one change here that touches another crate, and #11 is `state/proposed` around the getrandom error alone. It is ordered first so that every commit builds: the reverse order would leave an intermediate commit still failing the wasm check on `mio`. WARNING: this does NOT reach `sylpheed-export`, which builds `sylpheed-formats` from the git pin `formats-pin-2026-09-01` (`e2630413`, contained in `auto/frame-blend-draw-path` only) rather than the workspace path crate. The dependency is not gone tree-wide until that pin resolves, so anyone later adding `-p sylpheed-export` to the WASM job will hit `mio` with this fix apparently already applied. Refs #11 Co-Authored-By: Claude Opus 5 --- crates/sylpheed-formats/Cargo.toml | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/crates/sylpheed-formats/Cargo.toml b/crates/sylpheed-formats/Cargo.toml index 1cd5d220..b08124e6 100644 --- a/crates/sylpheed-formats/Cargo.toml +++ b/crates/sylpheed-formats/Cargo.toml @@ -11,7 +11,12 @@ xdvdfs = { workspace = true } binrw = { workspace = true } flate2 = "1" # zlib/DEFLATE for IPFB "Z1" entries (miniz_oxide backend, WASM-safe) ttf-parser = { version = "0.24", default-features = false, features = ["std", "opentype-layout"] } # font metadata (OTF/TTF/ttcf), WASM-safe -tokio = { workspace = true } +# tokio is a DEV dependency only (see [dev-dependencies] below). Every use in +# this crate is inside a `mod tests`: three runtime builders in ship.rs and one +# `#[tokio::test]` in xiso.rs. As a normal dependency it pulled `tokio/full`, +# whose `net` feature drags in `mio`, which does not build for wasm32 — +# error: This wasm target is unsupported by mio. +# so the unused dependency was breaking the WASM job. futures = { workspace = true } thiserror = { workspace = true } anyhow = { workspace = true }