diff --git a/MODERNIZE.md b/MODERNIZE.md index 343617d..78bdc15 100644 --- a/MODERNIZE.md +++ b/MODERNIZE.md @@ -9,23 +9,28 @@ Status notes: - Toolchain decision: stay on nightly (channel = "nightly"). The stable-Rust item is listed for awareness only. - The item 3.2 note about the double `foundry.json` load stays true. +- Dependency decision (2026-08-04): `itertools`, `thiserror`, `anyhow`, + `pretty_env_logger`, `dotenvy` stay for certain. The rest of section 1 + is under consideration. -## 1. Delete unused dependencies +## 1. Unused dependencies -Remove these from `Cargo.toml`. None are referenced in `src/`: +None of these are referenced in `src/`. Decision: `itertools`, `thiserror`, +`anyhow`, `pretty_env_logger` and `dotenvy` stay for certain. The rest is +under consideration. | dependency | note | |---|---| -| `itertools` | no usage | -| `seq-macro` | no usage | -| `leptos-use` | no usage | -| `dotenvy` | no usage. Never wired into `main` | -| `pretty_env_logger` | no usage. Logging uses the `log` macros | -| `thiserror` | no usage. No error types yet | -| `http` | optional, enabled by no feature. Code uses `actix_web::http::StatusCode` | -| `console_log` | no usage. Only `console_error_panic_hook` is called | -| `anyhow` | only `#[macro_use] extern crate anyhow` and prelude aliases. The `Result` alias and `bail!`/`anyhow!` are used nowhere | -| `js-sys` | no direct usage. Resolves transitively. Keep the `wasm-bindgen =0.2.126` pin: `hydrate()` uses `#[wasm_bindgen(...)]` | +| `itertools` | **keep for now** (decision). No usage | +| `seq-macro` | under consideration. No usage | +| `leptos-use` | under consideration. No usage | +| `dotenvy` | **keep for now** (decision). No usage. Never wired into `main` | +| `pretty_env_logger` | **keep for now** (decision). No usage. Logging uses the `log` macros | +| `thiserror` | **keep for now** (decision). No usage. No error types yet | +| `http` | under consideration. Optional, enabled by no feature. Code uses `actix_web::http::StatusCode` | +| `console_log` | under consideration. No usage. Only `console_error_panic_hook` is called | +| `anyhow` | **keep for now** (decision). Only `#[macro_use] extern crate anyhow` and prelude aliases. The `Result` alias and `bail!`/`anyhow!` are used nowhere | +| `js-sys` | under consideration. No direct usage. Resolves transitively. Keep the `wasm-bindgen =0.2.126` pin: `hydrate()` uses `#[wasm_bindgen(...)]` | ## 2. Replace crates with std or small local code @@ -68,7 +73,9 @@ Remove these from `Cargo.toml`. None are referenced in `src/`: in `Cargo.toml`. Phase 1 (persistence) re-adds `serde = { version = "1", features = ["derive"] }`. -Result: `[dependencies]` drops from 27 entries to about 13. +Result: dropping the under-consideration items takes `[dependencies]` from +27 entries to about 18. If the five kept deps are dropped later too, it goes +to about 13. ## 3. Idiomatic cleanups (no dependency changes) @@ -87,7 +94,8 @@ Result: `[dependencies]` drops from 27 entries to about 13. `#![allow(dead_code)]`. They hide real warnings. - Remove the single-letter `log` aliases (`warn as w, log as l, info as i, ...`). They are unused. - - Remove the `anyhow` re-exports and typealiases. + - Remove the `anyhow` re-exports and typealiases. Keeping the `anyhow` + dependency does not force keeping these dead re-exports. - Replace legacy `#[macro_use] extern crate log;` in `src/lib.rs` with `use log::{info, error};` at the two call sites. diff --git a/ROADMAP.md b/ROADMAP.md index 03e9cb5..700dcdb 100644 --- a/ROADMAP.md +++ b/ROADMAP.md @@ -60,7 +60,9 @@ Cheap, unblocks the rest. Can happen any time; do it first. - [ ] decide Cargo.lock policy — currently gitignored, builds are non-reproducible; commit it - [ ] dependency and idiom cleanup — see `MODERNIZE.md` (drop unused deps, `lazy_static` → `LazyLock`, local replacements for `num-format`/`num-traits`) -- [ ] drop unused dependencies (`leptos-use`, `dotenvy`, `pretty_env_logger` if confirmed unused) +- [ ] decide on the under-consideration unused deps from `MODERNIZE.md` + (`seq-macro`, `leptos-use`, `http`, `console_log`, `js-sys`); the rest + (`itertools`, `thiserror`, `anyhow`, `pretty_env_logger`, `dotenvy`) stay - [ ] replace `end2end/tests/example.spec.ts` with a smoke test (app boots, nav renders, no console errors) ## Phase 1 — Persistence: localStorage + JSON export/import (L, ~3-5 days)