mirror of https://github.com/astral-sh/uv
Update Rust crate fs-err to v3 (#8625)
This commit is contained in:
parent
07806c404a
commit
dae630ae50
|
|
@ -1155,6 +1155,15 @@ name = "fs-err"
|
|||
version = "2.11.0"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "88a41f105fe1d5b6b34b2055e3dc59bb79b46b48b2040b9e6c7b4b5de097aa41"
|
||||
dependencies = [
|
||||
"autocfg",
|
||||
]
|
||||
|
||||
[[package]]
|
||||
name = "fs-err"
|
||||
version = "3.0.0"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "8bb60e7409f34ef959985bc9d9c5ee8f5db24ee46ed9775850548021710f807f"
|
||||
dependencies = [
|
||||
"autocfg",
|
||||
"tokio",
|
||||
|
|
@ -4108,7 +4117,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index"
|
|||
checksum = "382e025ef8e0db646343dd2cf56af9d7fe6f5eabce5f388f8e5ec7234f555a0f"
|
||||
dependencies = [
|
||||
"anyhow",
|
||||
"fs-err",
|
||||
"fs-err 2.11.0",
|
||||
"itertools 0.13.0",
|
||||
"once_cell",
|
||||
"rustc-hash",
|
||||
|
|
@ -4401,7 +4410,7 @@ dependencies = [
|
|||
"etcetera",
|
||||
"filetime",
|
||||
"flate2",
|
||||
"fs-err",
|
||||
"fs-err 3.0.0",
|
||||
"futures",
|
||||
"http",
|
||||
"ignore",
|
||||
|
|
@ -4539,7 +4548,7 @@ version = "0.1.0"
|
|||
dependencies = [
|
||||
"csv",
|
||||
"flate2",
|
||||
"fs-err",
|
||||
"fs-err 3.0.0",
|
||||
"globset",
|
||||
"indoc",
|
||||
"insta",
|
||||
|
|
@ -4571,7 +4580,7 @@ version = "0.0.1"
|
|||
dependencies = [
|
||||
"anstream",
|
||||
"anyhow",
|
||||
"fs-err",
|
||||
"fs-err 3.0.0",
|
||||
"indoc",
|
||||
"insta",
|
||||
"itertools 0.13.0",
|
||||
|
|
@ -4603,7 +4612,7 @@ name = "uv-cache"
|
|||
version = "0.0.1"
|
||||
dependencies = [
|
||||
"clap",
|
||||
"fs-err",
|
||||
"fs-err 3.0.0",
|
||||
"nanoid",
|
||||
"rmp-serde",
|
||||
"rustc-hash",
|
||||
|
|
@ -4626,7 +4635,7 @@ dependencies = [
|
|||
name = "uv-cache-info"
|
||||
version = "0.0.1"
|
||||
dependencies = [
|
||||
"fs-err",
|
||||
"fs-err 3.0.0",
|
||||
"globwalk",
|
||||
"schemars",
|
||||
"serde",
|
||||
|
|
@ -4652,7 +4661,7 @@ dependencies = [
|
|||
"anyhow",
|
||||
"clap",
|
||||
"clap_complete_command",
|
||||
"fs-err",
|
||||
"fs-err 3.0.0",
|
||||
"insta",
|
||||
"serde",
|
||||
"url",
|
||||
|
|
@ -4680,7 +4689,7 @@ dependencies = [
|
|||
"async_http_range_reader",
|
||||
"async_zip",
|
||||
"bytecheck",
|
||||
"fs-err",
|
||||
"fs-err 3.0.0",
|
||||
"futures",
|
||||
"html-escape",
|
||||
"http",
|
||||
|
|
@ -4730,7 +4739,7 @@ dependencies = [
|
|||
"anyhow",
|
||||
"clap",
|
||||
"either",
|
||||
"fs-err",
|
||||
"fs-err 3.0.0",
|
||||
"rustc-hash",
|
||||
"schemars",
|
||||
"serde",
|
||||
|
|
@ -4766,7 +4775,7 @@ dependencies = [
|
|||
"anstream",
|
||||
"anyhow",
|
||||
"clap",
|
||||
"fs-err",
|
||||
"fs-err 3.0.0",
|
||||
"itertools 0.13.0",
|
||||
"markdown",
|
||||
"owo-colors",
|
||||
|
|
@ -4838,7 +4847,7 @@ version = "0.0.1"
|
|||
dependencies = [
|
||||
"anyhow",
|
||||
"either",
|
||||
"fs-err",
|
||||
"fs-err 3.0.0",
|
||||
"futures",
|
||||
"indoc",
|
||||
"insta",
|
||||
|
|
@ -4898,7 +4907,7 @@ version = "0.0.1"
|
|||
dependencies = [
|
||||
"anyhow",
|
||||
"bitflags 2.6.0",
|
||||
"fs-err",
|
||||
"fs-err 3.0.0",
|
||||
"itertools 0.13.0",
|
||||
"jiff",
|
||||
"petgraph",
|
||||
|
|
@ -4931,7 +4940,7 @@ version = "0.0.1"
|
|||
dependencies = [
|
||||
"async-compression",
|
||||
"async_zip",
|
||||
"fs-err",
|
||||
"fs-err 3.0.0",
|
||||
"futures",
|
||||
"krata-tokio-tar",
|
||||
"md-5",
|
||||
|
|
@ -4958,7 +4967,7 @@ dependencies = [
|
|||
"dunce",
|
||||
"either",
|
||||
"encoding_rs_io",
|
||||
"fs-err",
|
||||
"fs-err 3.0.0",
|
||||
"fs2",
|
||||
"junction",
|
||||
"path-slash",
|
||||
|
|
@ -4979,7 +4988,7 @@ dependencies = [
|
|||
"anyhow",
|
||||
"cargo-util",
|
||||
"dashmap",
|
||||
"fs-err",
|
||||
"fs-err 3.0.0",
|
||||
"reqwest",
|
||||
"reqwest-middleware",
|
||||
"serde",
|
||||
|
|
@ -4998,7 +5007,7 @@ dependencies = [
|
|||
name = "uv-globfilter"
|
||||
version = "0.1.0"
|
||||
dependencies = [
|
||||
"fs-err",
|
||||
"fs-err 2.11.0",
|
||||
"globset",
|
||||
"insta",
|
||||
"regex",
|
||||
|
|
@ -5019,7 +5028,7 @@ dependencies = [
|
|||
"configparser",
|
||||
"csv",
|
||||
"data-encoding",
|
||||
"fs-err",
|
||||
"fs-err 3.0.0",
|
||||
"indoc",
|
||||
"mailparse",
|
||||
"pathdiff",
|
||||
|
|
@ -5056,7 +5065,7 @@ version = "0.0.1"
|
|||
dependencies = [
|
||||
"anyhow",
|
||||
"async-channel",
|
||||
"fs-err",
|
||||
"fs-err 3.0.0",
|
||||
"futures",
|
||||
"rayon",
|
||||
"rustc-hash",
|
||||
|
|
@ -5101,7 +5110,7 @@ name = "uv-metadata"
|
|||
version = "0.1.0"
|
||||
dependencies = [
|
||||
"async_zip",
|
||||
"fs-err",
|
||||
"fs-err 3.0.0",
|
||||
"futures",
|
||||
"thiserror 2.0.3",
|
||||
"tokio",
|
||||
|
|
@ -5206,7 +5215,7 @@ version = "0.1.0"
|
|||
dependencies = [
|
||||
"async-compression",
|
||||
"base64 0.22.1",
|
||||
"fs-err",
|
||||
"fs-err 3.0.0",
|
||||
"futures",
|
||||
"glob",
|
||||
"insta",
|
||||
|
|
@ -5272,7 +5281,7 @@ dependencies = [
|
|||
"assert_fs",
|
||||
"clap",
|
||||
"configparser",
|
||||
"fs-err",
|
||||
"fs-err 3.0.0",
|
||||
"futures",
|
||||
"goblin",
|
||||
"indoc",
|
||||
|
|
@ -5326,7 +5335,7 @@ dependencies = [
|
|||
"anyhow",
|
||||
"configparser",
|
||||
"console",
|
||||
"fs-err",
|
||||
"fs-err 3.0.0",
|
||||
"futures",
|
||||
"rustc-hash",
|
||||
"serde",
|
||||
|
|
@ -5359,7 +5368,7 @@ version = "0.0.1"
|
|||
dependencies = [
|
||||
"anyhow",
|
||||
"assert_fs",
|
||||
"fs-err",
|
||||
"fs-err 3.0.0",
|
||||
"indoc",
|
||||
"insta",
|
||||
"itertools 0.13.0",
|
||||
|
|
@ -5440,7 +5449,7 @@ dependencies = [
|
|||
name = "uv-scripts"
|
||||
version = "0.0.1"
|
||||
dependencies = [
|
||||
"fs-err",
|
||||
"fs-err 3.0.0",
|
||||
"indoc",
|
||||
"memchr",
|
||||
"serde",
|
||||
|
|
@ -5461,7 +5470,7 @@ dependencies = [
|
|||
"assert_fs",
|
||||
"clap",
|
||||
"etcetera",
|
||||
"fs-err",
|
||||
"fs-err 3.0.0",
|
||||
"indoc",
|
||||
"schemars",
|
||||
"serde",
|
||||
|
|
@ -5503,7 +5512,7 @@ dependencies = [
|
|||
name = "uv-state"
|
||||
version = "0.0.1"
|
||||
dependencies = [
|
||||
"fs-err",
|
||||
"fs-err 3.0.0",
|
||||
"tempfile",
|
||||
"uv-dirs",
|
||||
]
|
||||
|
|
@ -5519,7 +5528,7 @@ dependencies = [
|
|||
name = "uv-tool"
|
||||
version = "0.0.1"
|
||||
dependencies = [
|
||||
"fs-err",
|
||||
"fs-err 3.0.0",
|
||||
"pathdiff",
|
||||
"serde",
|
||||
"thiserror 2.0.3",
|
||||
|
|
@ -5548,7 +5557,7 @@ dependencies = [
|
|||
"anyhow",
|
||||
"assert_cmd",
|
||||
"assert_fs",
|
||||
"fs-err",
|
||||
"fs-err 3.0.0",
|
||||
"thiserror 2.0.3",
|
||||
"uv-fs",
|
||||
"which",
|
||||
|
|
@ -5583,7 +5592,7 @@ version = "0.5.2"
|
|||
name = "uv-virtualenv"
|
||||
version = "0.0.4"
|
||||
dependencies = [
|
||||
"fs-err",
|
||||
"fs-err 3.0.0",
|
||||
"itertools 0.13.0",
|
||||
"pathdiff",
|
||||
"thiserror 2.0.3",
|
||||
|
|
@ -5611,7 +5620,7 @@ version = "0.0.1"
|
|||
dependencies = [
|
||||
"anyhow",
|
||||
"assert_fs",
|
||||
"fs-err",
|
||||
"fs-err 3.0.0",
|
||||
"glob",
|
||||
"insta",
|
||||
"itertools 0.13.0",
|
||||
|
|
@ -5867,7 +5876,7 @@ version = "0.1.9"
|
|||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "cf221c93e13a30d793f7645a0e7762c55d169dbb0a49671918a2319d289b10bb"
|
||||
dependencies = [
|
||||
"windows-sys 0.48.0",
|
||||
"windows-sys 0.59.0",
|
||||
]
|
||||
|
||||
[[package]]
|
||||
|
|
|
|||
|
|
@ -98,7 +98,7 @@ either = { version = "1.13.0" }
|
|||
encoding_rs_io = { version = "0.1.7" }
|
||||
etcetera = { version = "0.8.0" }
|
||||
flate2 = { version = "1.0.33", default-features = false }
|
||||
fs-err = { version = "2.11.0" }
|
||||
fs-err = { version = "3.0.0" }
|
||||
fs2 = { version = "0.4.3" }
|
||||
futures = { version = "0.3.30" }
|
||||
glob = { version = "0.3.1" }
|
||||
|
|
|
|||
|
|
@ -43,5 +43,5 @@ workspace = true
|
|||
|
||||
[dev-dependencies]
|
||||
indoc = { version = "2.0.5" }
|
||||
insta = { version = "1.40.0" }
|
||||
insta = { version = "1.40.0", features = ["filters"] }
|
||||
tempfile = { version = "3.12.0" }
|
||||
|
|
|
|||
|
|
@ -1022,8 +1022,15 @@ mod tests {
|
|||
.unwrap()
|
||||
.to_metadata(Path::new("/do/not/read"))
|
||||
.unwrap_err();
|
||||
// Simplified for windows compatibility.
|
||||
assert_snapshot!(err.to_string().replace('\\', "/"), @"failed to open file `/do/not/read/Readme.md`");
|
||||
// Strip away OS specific part.
|
||||
let err = err
|
||||
.to_string()
|
||||
.replace('\\', "/")
|
||||
.split_once(':')
|
||||
.unwrap()
|
||||
.0
|
||||
.to_string();
|
||||
assert_snapshot!(err, @"failed to open file `/do/not/read/Readme.md`");
|
||||
}
|
||||
|
||||
#[test]
|
||||
|
|
|
|||
|
|
@ -1406,13 +1406,19 @@ mod test {
|
|||
let filters = vec![
|
||||
(requirement_txt.as_str(), "<REQUIREMENTS_TXT>"),
|
||||
(missing_txt.as_str(), "<MISSING_TXT>"),
|
||||
// Windows translates error messages, for example i get:
|
||||
// "Das System kann den angegebenen Pfad nicht finden. (os error 3)"
|
||||
(
|
||||
r": .* \(os error 2\)",
|
||||
": The system cannot find the path specified. (os error 2)",
|
||||
),
|
||||
];
|
||||
insta::with_settings!({
|
||||
filters => filters,
|
||||
}, {
|
||||
insta::assert_snapshot!(errors, @r###"
|
||||
Error parsing included file in `<REQUIREMENTS_TXT>` at position 0
|
||||
failed to read from file `<MISSING_TXT>`
|
||||
failed to read from file `<MISSING_TXT>`: The system cannot find the path specified. (os error 2)
|
||||
"###);
|
||||
});
|
||||
|
||||
|
|
|
|||
|
|
@ -187,9 +187,9 @@ dependencies = [
|
|||
|
||||
[[package]]
|
||||
name = "fs-err"
|
||||
version = "2.11.0"
|
||||
version = "3.0.0"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "88a41f105fe1d5b6b34b2055e3dc59bb79b46b48b2040b9e6c7b4b5de097aa41"
|
||||
checksum = "8bb60e7409f34ef959985bc9d9c5ee8f5db24ee46ed9775850548021710f807f"
|
||||
dependencies = [
|
||||
"autocfg",
|
||||
]
|
||||
|
|
|
|||
|
|
@ -56,7 +56,7 @@ embed-manifest = "1.4.0"
|
|||
anyhow = { version = "1.0.80" }
|
||||
assert_cmd = { version = "2.0.14" }
|
||||
assert_fs = { version = "1.1.1" }
|
||||
fs-err = { version = "2.11.0" }
|
||||
fs-err = { version = "3.0.0" }
|
||||
thiserror = { version = "2.0.0" }
|
||||
which = { version = "7.0.0" }
|
||||
zip = { version = "0.6.6", default-features = false, features = ["deflate"] }
|
||||
|
|
|
|||
|
|
@ -2850,8 +2850,7 @@ fn run_script_explicit_directory() -> Result<()> {
|
|||
----- stdout -----
|
||||
|
||||
----- stderr -----
|
||||
error: failed to read from file `script`
|
||||
Caused by: Is a directory (os error 21)
|
||||
error: failed to read from file `script`: Is a directory (os error 21)
|
||||
"###);
|
||||
|
||||
Ok(())
|
||||
|
|
|
|||
|
|
@ -1067,10 +1067,10 @@ fn path_with_trailing_space_gives_proper_error() {
|
|||
let path_with_trailing_slash = format!("{} ", context.cache_dir.path().display());
|
||||
let mut filters = context.filters();
|
||||
// Windows translates error messages, for example i get:
|
||||
// "Caused by: Das System kann den angegebenen Pfad nicht finden. (os error 3)"
|
||||
// ": Das System kann den angegebenen Pfad nicht finden. (os error 3)"
|
||||
filters.push((
|
||||
r"Caused by: .* \(os error 3\)",
|
||||
"Caused by: The system cannot find the path specified. (os error 3)",
|
||||
r"CACHEDIR.TAG`: .* \(os error 3\)",
|
||||
"CACHEDIR.TAG`: The system cannot find the path specified. (os error 3)",
|
||||
));
|
||||
uv_snapshot!(filters, std::process::Command::new(crate::common::get_bin())
|
||||
.arg("venv")
|
||||
|
|
@ -1080,8 +1080,7 @@ fn path_with_trailing_space_gives_proper_error() {
|
|||
----- stdout -----
|
||||
|
||||
----- stderr -----
|
||||
error: failed to open file `[CACHE_DIR]/ /CACHEDIR.TAG`
|
||||
Caused by: The system cannot find the path specified. (os error 3)
|
||||
error: failed to open file `[CACHE_DIR]/ /CACHEDIR.TAG`: The system cannot find the path specified. (os error 3)
|
||||
"###
|
||||
);
|
||||
// Note the extra trailing `/` in the snapshot is due to the filters, not the actual output.
|
||||
|
|
|
|||
Loading…
Reference in New Issue