cargo-bless 0.2.5

Modernize your Rust dependencies with blessed.rs + live intel
Documentation
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
[
  {
    "pattern": "chrono",
    "replacement": "time",
    "kind": "ModernAlternative",
    "reason": "Consider evaluating the `time` crate for simpler datetime needs — not a mandate to replace `chrono`; chrono remains maintained and is often correct for timezone-heavy work",
    "source": "blessed.rs",
    "condition": "UTC-only or simple datetime usage",
    "confidence": "Low",
    "migration_risk": "Medium",
    "autofix_safety": "ManualOnly",
    "evidence_source": "BlessedRs"
  },
  {
    "pattern": "lazy_static",
    "replacement": "std::sync::LazyLock",
    "kind": "StdReplacement",
    "reason": "LazyLock is stable since Rust 1.80 and can remove an extra dependency after source imports are updated",
    "source": "std docs",
    "condition": null,
    "confidence": "High",
    "migration_risk": "Low",
    "autofix_safety": "ManualOnly",
    "evidence_source": "StdDocs"
  },
  {
    "pattern": "once_cell",
    "replacement": "std::sync::LazyLock / OnceLock",
    "kind": "StdReplacement",
    "reason": "LazyLock and OnceLock are stable since Rust 1.80 and may cover common once_cell usage after source imports are updated",
    "source": "std docs",
    "condition": null,
    "confidence": "High",
    "migration_risk": "Low",
    "autofix_safety": "ManualOnly",
    "evidence_source": "StdDocs"
  },
  {
    "pattern": "structopt",
    "replacement": "clap v4 (derive)",
    "kind": "ModernAlternative",
    "reason": "structopt functionality was folded into clap derive; migrate when you are ready to update CLI derives and attributes",
    "source": "blessed.rs",
    "condition": null,
    "confidence": "High",
    "migration_risk": "Medium",
    "autofix_safety": "ManualOnly",
    "evidence_source": "BlessedRs"
  },
  {
    "pattern": "actix-web",
    "replacement": "axum",
    "kind": "ModernAlternative",
    "reason": "axum is a common Tokio-native choice for new services, but actix-web remains maintained; treat this as an ecosystem preference, not a mandatory migration",
    "source": "blessed.rs",
    "condition": null,
    "confidence": "Low",
    "migration_risk": "High",
    "autofix_safety": "ManualOnly",
    "evidence_source": "BlessedRs"
  },
  {
    "pattern": "iron",
    "replacement": "axum",
    "kind": "Unmaintained",
    "reason": "Iron is no longer a good foundation for new Rust web services; axum is a maintained Tokio-native migration target",
    "source": "blessed.rs",
    "condition": null,
    "confidence": "High",
    "migration_risk": "High",
    "autofix_safety": "ManualOnly",
    "evidence_source": "BlessedRs"
  },
  {
    "pattern": "memmap",
    "replacement": "memmap2",
    "kind": "Unmaintained",
    "reason": "memmap is unmaintained; memmap2 is the maintained fork, but source imports and API details still need review",
    "source": "RustSec",
    "condition": null,
    "confidence": "High",
    "migration_risk": "Medium",
    "autofix_safety": "ManualOnly",
    "evidence_source": "RustSec"
  },
  {
    "pattern": "failure",
    "replacement": "anyhow + thiserror",
    "kind": "Unmaintained",
    "reason": "failure is deprecated and unmaintained; anyhow for application errors and thiserror for library errors is the common modern split",
    "source": "blessed.rs",
    "condition": null,
    "confidence": "High",
    "migration_risk": "Medium",
    "autofix_safety": "ManualOnly",
    "evidence_source": "BlessedRs"
  },
  {
    "pattern": "log",
    "replacement": "tracing",
    "kind": "ModernAlternative",
    "reason": "tracing adds structured spans and async-aware instrumentation, but log is still maintained and may be enough for simple libraries",
    "source": "blessed.rs",
    "condition": null,
    "confidence": "Medium",
    "migration_risk": "Medium",
    "autofix_safety": "ManualOnly",
    "evidence_source": "BlessedRs"
  },
  {
    "pattern": "reqwest+serde_json",
    "replacement": "reqwest with \"json\" feature",
    "kind": "FeatureOptimization",
    "reason": "reqwest can deserialize JSON directly when its json feature is enabled; cargo-bless only suggests this when serde_json is not used directly in source",
    "source": "reqwest docs",
    "condition": null,
    "confidence": "High",
    "migration_risk": "Low",
    "autofix_safety": "CargoTomlOnly",
    "evidence_source": "CrateDocs"
  },
  {
    "pattern": "tokio+async-std",
    "replacement": "tokio only",
    "kind": "ComboWin",
    "reason": "using two async runtimes usually adds complexity; consolidate only after checking runtime boundaries and dependencies",
    "source": "blessed.rs",
    "condition": null,
    "confidence": "Medium",
    "migration_risk": "High",
    "autofix_safety": "ManualOnly",
    "evidence_source": "BlessedRs"
  },
  {
    "pattern": "env_logger",
    "replacement": "tracing-subscriber",
    "kind": "ModernAlternative",
    "reason": "tracing-subscriber pairs with tracing for structured, filterable logging; keep env_logger if log-based output is intentionally simple",
    "source": "blessed.rs",
    "condition": null,
    "confidence": "Medium",
    "migration_risk": "Medium",
    "autofix_safety": "ManualOnly",
    "evidence_source": "BlessedRs"
  },
  {
    "pattern": "log+env_logger",
    "replacement": "tracing + tracing-subscriber",
    "kind": "ComboWin",
    "reason": "tracing plus tracing-subscriber is the modern observability stack, but migration requires source instrumentation choices",
    "source": "blessed.rs",
    "condition": null,
    "confidence": "Medium",
    "migration_risk": "Medium",
    "autofix_safety": "ManualOnly",
    "evidence_source": "BlessedRs"
  },
  {
    "pattern": "warp",
    "replacement": "axum",
    "kind": "ModernAlternative",
    "reason": "axum is the more active Tokio-native web framework choice for new projects; migration from warp should be deliberate",
    "source": "blessed.rs",
    "condition": null,
    "confidence": "Medium",
    "migration_risk": "High",
    "autofix_safety": "ManualOnly",
    "evidence_source": "BlessedRs"
  },
  {
    "pattern": "rocket",
    "replacement": "axum",
    "kind": "ModernAlternative",
    "reason": "axum is a common lightweight Tokio-native choice, but Rocket may still be appropriate if its ergonomics are important to the project",
    "source": "blessed.rs",
    "condition": null,
    "confidence": "Low",
    "migration_risk": "High",
    "autofix_safety": "ManualOnly",
    "evidence_source": "BlessedRs"
  },
  {
    "pattern": "maplit",
    "replacement": "std::collections::HashMap::from / BTreeMap::from",
    "kind": "StdReplacement",
    "reason": "std collection constructors cover many maplit use cases after source macros are rewritten",
    "source": "std docs",
    "condition": null,
    "confidence": "High",
    "migration_risk": "Low",
    "autofix_safety": "ManualOnly",
    "evidence_source": "StdDocs"
  },
  {
    "pattern": "error-chain",
    "replacement": "anyhow + thiserror",
    "kind": "Unmaintained",
    "reason": "error-chain is in maintenance mode; anyhow for app errors and thiserror for library errors is the common modern split",
    "source": "blessed.rs",
    "condition": null,
    "confidence": "High",
    "migration_risk": "Medium",
    "autofix_safety": "ManualOnly",
    "evidence_source": "BlessedRs"
  },
  {
    "pattern": "proc-macro-error",
    "replacement": "syn::Error or proc-macro-error2",
    "kind": "ModernAlternative",
    "reason": "proc-macro diagnostics need compile-time errors with spans; syn::Error is the standard baseline and proc-macro-error2 is an ergonomic option",
    "source": "crate docs",
    "condition": null,
    "confidence": "Medium",
    "migration_risk": "Medium",
    "autofix_safety": "ManualOnly",
    "evidence_source": "CrateDocs"
  },
  {
    "pattern": "derivative",
    "replacement": "derive_more",
    "kind": "Unmaintained",
    "reason": "derivative appears inactive; derive_more may cover many derive helper use cases, but macro behavior needs source review",
    "source": "crates.io",
    "condition": null,
    "confidence": "Medium",
    "migration_risk": "Medium",
    "autofix_safety": "ManualOnly",
    "evidence_source": "CratesIo"
  },
  {
    "pattern": "anyhow+error-chain",
    "replacement": "anyhow only (app) or thiserror (lib)",
    "kind": "ComboWin",
    "reason": "error-chain and anyhow overlap; pick one error handling pattern based on whether this is an application or library boundary",
    "source": "blessed.rs",
    "condition": null,
    "confidence": "High",
    "migration_risk": "Medium",
    "autofix_safety": "ManualOnly",
    "evidence_source": "BlessedRs"
  },
  {
    "pattern": "bytes+try_from_bytes",
    "replacement": "bytes with built-in zero-copy slicing",
    "kind": "FeatureOptimization",
    "reason": "bytes already provides the core zero-copy byte buffer primitives; verify the helper crate is not adding project-specific parsing behavior",
    "source": "bytes docs",
    "condition": null,
    "confidence": "Medium",
    "migration_risk": "Low",
    "autofix_safety": "ManualOnly",
    "evidence_source": "CrateDocs"
  },
  {
    "pattern": "num_cpus",
    "replacement": "std::thread::available_parallelism",
    "kind": "StdReplacement",
    "reason": "available_parallelism covers common CPU count queries in std after source calls are updated",
    "source": "std docs",
    "condition": null,
    "confidence": "High",
    "migration_risk": "Low",
    "autofix_safety": "ManualOnly",
    "evidence_source": "StdDocs"
  },
  {
    "pattern": "rustc-serialize",
    "replacement": "serde",
    "kind": "Unmaintained",
    "reason": "rustc-serialize is obsolete; serde is the standard serialization ecosystem, but migration is a real source change",
    "source": "blessed.rs",
    "condition": null,
    "confidence": "High",
    "migration_risk": "High",
    "autofix_safety": "ManualOnly",
    "evidence_source": "BlessedRs"
  },
  {
    "pattern": "serde_derive",
    "replacement": "serde with \"derive\" feature",
    "kind": "FeatureOptimization",
    "reason": "serde exposes derive through its own feature; this can usually remove the separate serde_derive dependency without source rewrites",
    "source": "serde docs",
    "condition": null,
    "confidence": "High",
    "migration_risk": "Low",
    "autofix_safety": "CargoTomlOnly",
    "evidence_source": "CrateDocs"
  },
  {
    "pattern": "crossbeam-utils",
    "replacement": "std::sync primitives or parking_lot",
    "kind": "ModernAlternative",
    "reason": "some crossbeam-utils use cases are now covered by std, while parking_lot may fit some locking needs; inspect actual APIs before changing",
    "source": "blessed.rs",
    "condition": null,
    "confidence": "Low",
    "migration_risk": "Medium",
    "autofix_safety": "ManualOnly",
    "evidence_source": "BlessedRs"
  },
  {
    "pattern": "hyper+serde_json",
    "replacement": "axum with built-in JSON support",
    "kind": "ComboWin",
    "reason": "axum can reduce boilerplate for application HTTP JSON handling, but hyper remains right for lower-level HTTP code",
    "source": "blessed.rs",
    "condition": null,
    "confidence": "Low",
    "migration_risk": "High",
    "autofix_safety": "ManualOnly",
    "evidence_source": "BlessedRs"
  },
  {
    "pattern": "clap+clap_derive",
    "replacement": "clap with \"derive\" feature",
    "kind": "FeatureOptimization",
    "reason": "clap exposes derive through its own feature; this can usually remove the separate clap_derive dependency without source rewrites",
    "source": "clap docs",
    "condition": null,
    "confidence": "High",
    "migration_risk": "Low",
    "autofix_safety": "CargoTomlOnly",
    "evidence_source": "CrateDocs"
  },
  {
    "pattern": "quick-error",
    "replacement": "anyhow + thiserror",
    "kind": "Unmaintained",
    "reason": "quick-error is unmaintained since 2018 — anyhow (app) + thiserror (lib) is the modern standard",
    "source": "crates.io",
    "condition": null,
    "confidence": "Medium",
    "migration_risk": "Medium",
    "autofix_safety": "ManualOnly",
    "evidence_source": "Heuristic"
  },
  {
    "pattern": "failure_derive",
    "replacement": "thiserror",
    "kind": "Unmaintained",
    "reason": "failure_derive was part of the deprecated failure crate — thiserror provides better derive macros",
    "source": "blessed.rs",
    "condition": null,
    "confidence": "Medium",
    "migration_risk": "Medium",
    "autofix_safety": "ManualOnly",
    "evidence_source": "Heuristic"
  },
  {
    "pattern": "proc-macro-nested",
    "replacement": "no replacement needed (modern Rust handles nested macros)",
    "kind": "ModernAlternative",
    "reason": "proc-macro-nested was a workaround for old macro limitations — no longer needed in modern Rust",
    "source": "Rust RFC",
    "condition": null,
    "confidence": "Medium",
    "migration_risk": "Medium",
    "autofix_safety": "ManualOnly",
    "evidence_source": "Heuristic"
  },
  {
    "pattern": "version_check",
    "replacement": "rust-version in Cargo.toml or cfg_attr",
    "kind": "ModernAlternative",
    "reason": "version_check is a legacy crate for MSRV detection — use package.rust-version field instead",
    "source": "Cargo docs",
    "condition": null,
    "confidence": "Medium",
    "migration_risk": "Medium",
    "autofix_safety": "ManualOnly",
    "evidence_source": "Heuristic"
  },
  {
    "pattern": "semver",
    "replacement": "built-in version parsing or cargo_metadata",
    "kind": "ModernAlternative",
    "reason": "semver crate is rarely needed directly — use cargo_metadata for dependency resolution",
    "source": "blessed.rs",
    "condition": null,
    "confidence": "Medium",
    "migration_risk": "Medium",
    "autofix_safety": "ManualOnly",
    "evidence_source": "Heuristic"
  },
  {
    "pattern": "ggez",
    "replacement": "bevy",
    "kind": "ModernAlternative",
    "reason": "A simpler option for 2d games only.",
    "source": "blessed.rs",
    "condition": null,
    "confidence": "Medium",
    "migration_risk": "Medium",
    "autofix_safety": "ManualOnly",
    "evidence_source": "BlessedRs"
  },
  {
    "pattern": "serde_cbor",
    "replacement": "ciborium",
    "kind": "Unmaintained",
    "reason": "serde_cbor is officially abandoned — its README says 'This project is no longer maintained. Please use ciborium instead.' ciborium is the maintained RustCrypto replacement with a compatible API.",
    "source": "crates.io",
    "condition": null,
    "confidence": "High",
    "migration_risk": "Medium",
    "autofix_safety": "ManualOnly",
    "evidence_source": "CratesIo"
  },
  {
    "pattern": "serde_yaml",
    "replacement": "serde_yml",
    "kind": "Unmaintained",
    "reason": "serde_yaml was archived by its author (dtolnay) in 2024; serde_yml is the community-maintained fork with a compatible API and active releases.",
    "source": "crates.io",
    "condition": null,
    "confidence": "High",
    "migration_risk": "Low",
    "autofix_safety": "ManualOnly",
    "evidence_source": "CratesIo"
  },
  {
    "pattern": "tempdir",
    "replacement": "tempfile",
    "kind": "Unmaintained",
    "reason": "tempdir is deprecated — its crates.io page says 'Moved to tempfile::TempDir'. Last release was 2018; tempfile provides TempDir with the same API.",
    "source": "crates.io",
    "condition": null,
    "confidence": "High",
    "migration_risk": "Low",
    "autofix_safety": "ManualOnly",
    "evidence_source": "CratesIo"
  },
  {
    "pattern": "atty",
    "replacement": "std::io::IsTerminal",
    "kind": "StdReplacement",
    "reason": "std::io::IsTerminal was stabilized in Rust 1.70 and covers virtually all atty use cases; most crates have already migrated and atty is unmaintained.",
    "source": "std docs",
    "condition": null,
    "confidence": "High",
    "migration_risk": "Low",
    "autofix_safety": "ManualOnly",
    "evidence_source": "StdDocs"
  },
  {
    "pattern": "docopt",
    "replacement": "clap",
    "kind": "Unmaintained",
    "reason": "docopt is effectively unmaintained (no meaningful releases since 2021) and the Rust ecosystem has standardized on clap for CLI argument parsing.",
    "source": "crates.io",
    "condition": null,
    "confidence": "Medium",
    "migration_risk": "Medium",
    "autofix_safety": "ManualOnly",
    "evidence_source": "CratesIo"
  },
  {
    "pattern": "slog",
    "replacement": "tracing",
    "kind": "ModernAlternative",
    "reason": "slog is an older structured logging framework; tracing is the modern ecosystem choice with async-aware spans, compatible subscribers, and wider crate adoption.",
    "source": "blessed.rs",
    "condition": null,
    "confidence": "Medium",
    "migration_risk": "Medium",
    "autofix_safety": "ManualOnly",
    "evidence_source": "BlessedRs"
  },
  {
    "pattern": "ansi_term",
    "replacement": "owo-colors",
    "kind": "Unmaintained",
    "reason": "ansi_term was unmaintained for years; owo-colors is a zero-dependency, no-std-compatible alternative with an ergonomic API. nu-ansi-term is another maintained fork.",
    "source": "crates.io",
    "condition": null,
    "confidence": "Medium",
    "migration_risk": "Low",
    "autofix_safety": "ManualOnly",
    "evidence_source": "CratesIo"
  },
  {
    "pattern": "term",
    "replacement": "termcolor",
    "kind": "Unmaintained",
    "reason": "the term crate is old and rarely updated; termcolor is the BurntSushi-maintained replacement with cross-platform ANSI and Windows console support.",
    "source": "crates.io",
    "condition": null,
    "confidence": "Medium",
    "migration_risk": "Low",
    "autofix_safety": "ManualOnly",
    "evidence_source": "CratesIo"
  },
  {
    "pattern": "futures-preview",
    "replacement": "futures",
    "kind": "Unmaintained",
    "reason": "futures-preview was the pre-stabilization async crate — async/await has been stable since Rust 1.39; use the futures crate directly.",
    "source": "crates.io",
    "condition": null,
    "confidence": "High",
    "migration_risk": "Low",
    "autofix_safety": "ManualOnly",
    "evidence_source": "CratesIo"
  },
  {
    "pattern": "async-trait",
    "replacement": "native async fn in traits (Rust 1.75+)",
    "kind": "StdReplacement",
    "reason": "async fn in traits is stable since Rust 1.75 — async-trait is no longer needed for non-dyn trait usage. Note: if you use 'dyn Trait' with async methods, async-trait may still be required.",
    "source": "Rust RFC 3185",
    "condition": "non-dyn trait usage",
    "confidence": "Medium",
    "migration_risk": "Medium",
    "autofix_safety": "ManualOnly",
    "evidence_source": "StdDocs"
  }
]