Cargo build 在从源码构建 parity 后卡在 "Blocking waiting for file lock on the registry index"
大家好!我是 Rust 新手,正在尝试从源码构建 parity 项目(这是一个区块链节点)。克隆仓库并运行 `cargo build` 后,一切正常,但中途构建卡住了。终端显示消息:
```
Blocking waiting for file lock on the registry index
```
已经超过一小时没有任何进展。我尝试重启终端,但问题依旧。这是我的 `Cargo.toml`(简化版):
```toml
[package]
name = "my-parity-build"
version = "0.1.0"
edition = "2021"
[dependencies]
parity = { git = "https://github.com/paritytech/parity.git" }
```
系统:Ubuntu 22.04,Rust 通过 rustup 安装,最新稳定版。我已经尝试过:
- `cargo clean`
- 删除 `~/.cargo/registry/cache`
- 重启电脑
但都没有用。我哪里做错了?为什么 Cargo 无法访问包注册表?如何在不重新安装整个 Rust 的情况下修复?提前感谢帮助!