TimonPost / cargo-unused-features

Find potential unused enabled feature flags and prune them.
MIT License
230 stars 10 forks source link

Failing to prune from `report.json` #2

Closed MordechaiHadad closed 1 year ago

MordechaiHadad commented 1 year ago

Describe the bug Unable to prune from report.json

❯ unused-features prune --input report.json
A
B
[2022-10-28T09:30:29Z INFO  unused_features::subcommands::prune] Executing prune command.
[2022-10-28T09:30:29Z INFO  unused_features::report] Loading report from report.json.
[2022-10-28T09:30:29Z ERROR unused_features] Failed to deserialize report from report.json, maybe an old report? Current version is 0, make sure this is the same one in the report.

Only change I have made to the report.json file is removing from reqwest's successfully_remove_features the features rustls-tls and rustls-tls-webpki-roots

Provide the following information Cargo.toml

[dependencies]
clap = { version = "4.0.15", features = ["derive"] }
regex = "1.5"
serde = { version = "1.0", features = ["derive"] }
serde_json = "1.0"
reqwest = { version = "0.11", default-features = false, features = ["stream", "rustls-tls"] }
tokio = { version = "1.16.1", features = ["full"] }
anyhow = "1.0.52"
indicatif = "0.16.2"
futures-util = "0.3.14"
dirs = "4.0.0"
cfg-if = "1.0"
tracing = "0.1"
tracing-subscriber = "0.2"
yansi = "0.5.1"
TimonPost commented 1 year ago

Thanks for filing the issue. Are you sure the report is generated by the same version of the generating and reading library?

MordechaiHadad commented 1 year ago

I think so? I didn't really update anything...