{
  "id": "rust/cargo-msrv-version-conflict",
  "signature": "error: the package `crate_name` requires rustc >= X.Y.Z, but the current rustc version is A.B.C",
  "signature_zh": "错误：包 `crate_name` 要求 rustc >= X.Y.Z，但当前 rustc 版本是 A.B.C",
  "regex": "requires rustc >= \\d+\\.\\d+\\.\\d+",
  "domain": "rust",
  "category": "install_error",
  "subcategory": null,
  "root_cause": "A dependency or the package itself specifies a minimum supported Rust version (MSRV) higher than the currently installed Rust compiler version, causing a build failure.",
  "root_cause_type": "generic",
  "root_cause_zh": "依赖项或包本身指定的最低支持 Rust 版本（MSRV）高于当前安装的 Rust 编译器版本，导致构建失败。",
  "versions": [
    {
      "version": "rustc 1.70.0",
      "introduced": null,
      "deprecated": null,
      "removed": null,
      "behavior_change": null,
      "status": "active"
    },
    {
      "version": "rustc 1.71.0",
      "introduced": null,
      "deprecated": null,
      "removed": null,
      "behavior_change": null,
      "status": "active"
    },
    {
      "version": "rustc 1.72.0",
      "introduced": null,
      "deprecated": null,
      "removed": null,
      "behavior_change": null,
      "status": "active"
    },
    {
      "version": "cargo 1.70.0",
      "introduced": null,
      "deprecated": null,
      "removed": null,
      "behavior_change": null,
      "status": "active"
    }
  ],
  "os_specific": {},
  "dead_ends": [
    {
      "action": "",
      "why_fails": "This only affects the local package's MSRV, not the dependency's MSRV; the error comes from the dependency's requirement, which is enforced by Cargo.",
      "fail_rate": 0.9,
      "condition": "",
      "sources": []
    },
    {
      "action": "",
      "why_fails": "If all compatible versions of the dependency have the same or higher MSRV, `cargo update` won't resolve the issue; it may even pull a version with an even higher MSRV.",
      "fail_rate": 0.7,
      "condition": "",
      "sources": []
    },
    {
      "action": "",
      "why_fails": "This is fragile, requires maintaining a fork, and may break if the dependency uses features only available in newer Rust versions.",
      "fail_rate": 0.8,
      "condition": "",
      "sources": []
    }
  ],
  "workarounds": [
    {
      "action": "Update Rust to the required version using `rustup`: `rustup update stable` to get the latest stable, or `rustup install X.Y.Z && rustup default X.Y.Z` for a specific version.",
      "success_rate": 0.95,
      "how": "Update Rust to the required version using `rustup`: `rustup update stable` to get the latest stable, or `rustup install X.Y.Z && rustup default X.Y.Z` for a specific version.",
      "condition": "",
      "sources": []
    },
    {
      "action": "If you cannot update Rust, find an older version of the dependency that supports your Rust version by specifying an exact version in `Cargo.toml`: `crate_name = \"=1.2.3\"` where `1.2.3` is known to work.",
      "success_rate": 0.85,
      "how": "If you cannot update Rust, find an older version of the dependency that supports your Rust version by specifying an exact version in `Cargo.toml`: `crate_name = \"=1.2.3\"` where `1.2.3` is known to work.",
      "condition": "",
      "sources": []
    },
    {
      "action": "Use `cargo +nightly build` to temporarily use a nightly toolchain if the MSRV requirement is for stable, but note nightly may have other issues; better to use the specific required version.",
      "success_rate": 0.75,
      "how": "Use `cargo +nightly build` to temporarily use a nightly toolchain if the MSRV requirement is for stable, but note nightly may have other issues; better to use the specific required version.",
      "condition": "",
      "sources": []
    }
  ],
  "workarounds_zh": [
    "Update Rust to the required version using `rustup`: `rustup update stable` to get the latest stable, or `rustup install X.Y.Z && rustup default X.Y.Z` for a specific version.",
    "If you cannot update Rust, find an older version of the dependency that supports your Rust version by specifying an exact version in `Cargo.toml`: `crate_name = \"=1.2.3\"` where `1.2.3` is known to work.",
    "Use `cargo +nightly build` to temporarily use a nightly toolchain if the MSRV requirement is for stable, but note nightly may have other issues; better to use the specific required version."
  ],
  "transition_graph": {
    "leads_to": [],
    "preceded_by": [],
    "frequently_confused_with": []
  },
  "official_doc_url": "https://doc.rust-lang.org/cargo/reference/rust-version.html",
  "official_doc_section": null,
  "error_code": null,
  "verification_tier": "ai_generated",
  "confidence": 0.89,
  "fix_success_rate": 0.9,
  "resolvable": "true",
  "first_seen": "2024-03-01",
  "last_confirmed": "2024-06-01",
  "last_updated": "2024-06-01",
  "evidence_count": 1,
  "tags": [],
  "locale": "en",
  "aliases": []
}