From a7cba289bbaffdb3b1d1889aafec36539da81ed0 Mon Sep 17 00:00:00 2001 From: figsoda Date: Fri, 12 May 2023 14:09:35 -0400 Subject: [PATCH] ruff: 0.0.265 -> 0.0.267 Diff: https://github.com/charliermarsh/ruff/compare/v0.0.265...v0.0.267 Changelog: https://github.com/charliermarsh/ruff/releases/tag/v0.0.267 --- pkgs/development/tools/ruff/Cargo.lock | 377 +++--------------------- pkgs/development/tools/ruff/default.nix | 22 +- 2 files changed, 61 insertions(+), 338 deletions(-) diff --git a/pkgs/development/tools/ruff/Cargo.lock b/pkgs/development/tools/ruff/Cargo.lock index 98183d8a3a4e..a64472d67da5 100644 --- a/pkgs/development/tools/ruff/Cargo.lock +++ b/pkgs/development/tools/ruff/Cargo.lock @@ -138,21 +138,6 @@ dependencies = [ "os_str_bytes", ] -[[package]] -name = "ascii" -version = "1.1.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d92bec98840b8f03a5ff5413de5293bfcd8bf96467cf5452609f939ec6f5de16" - -[[package]] -name = "ascii-canvas" -version = "3.0.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8824ecca2e851cec16968d54a01dd372ef8f95b244fb84b84e70128be347c3c6" -dependencies = [ - "term", -] - [[package]] name = "assert_cmd" version = "2.0.11" @@ -160,7 +145,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "86d6b683edf8d1119fe420a94f8a7e389239666aa72e65495d91c00462510151" dependencies = [ "anstyle", - "bstr 1.4.0", + "bstr", "doc-comment", "predicates", "predicates-core", @@ -200,21 +185,6 @@ dependencies = [ "serde", ] -[[package]] -name = "bit-set" -version = "0.5.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0700ddab506f33b20a03b13996eccd309a48e5ff77d0d95926aa0210fb4e95f1" -dependencies = [ - "bit-vec", -] - -[[package]] -name = "bit-vec" -version = "0.6.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "349f9b6a179ed607305526ca489b34ad0a41aed5f7980fa90eb03160b69598fb" - [[package]] name = "bitflags" version = "1.3.2" @@ -223,20 +193,9 @@ checksum = "bef38d45163c2f1dde094a7dfd33ccf595c92905c8f8f4fdc18d06fb1037718a" [[package]] name = "bitflags" -version = "2.1.0" +version = "2.2.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c70beb79cbb5ce9c4f8e20849978f34225931f665bb49efa6982875a4d5facb3" - -[[package]] -name = "bstr" -version = "0.2.17" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ba3569f383e8f1598449f1a423e72e99569137b47740b1da11ef19af3d5c3223" -dependencies = [ - "lazy_static", - "memchr", - "regex-automata", -] +checksum = "24a6904aef64d73cf10ab17ebace7befb918b82164785cb89907993be7f83813" [[package]] name = "bstr" @@ -700,16 +659,6 @@ dependencies = [ "dirs-sys 0.4.0", ] -[[package]] -name = "dirs-next" -version = "2.0.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b98cf8ebf19c3d1b223e151f99a4f9f0690dca41414773390fc824184ac833e1" -dependencies = [ - "cfg-if", - "dirs-sys-next", -] - [[package]] name = "dirs-sys" version = "0.3.7" @@ -732,17 +681,6 @@ dependencies = [ "windows-sys 0.45.0", ] -[[package]] -name = "dirs-sys-next" -version = "0.1.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4ebda144c4fe02d1f7ea1a7d9641b6fc6b580adcfa024ae48797ecdeb6825b4d" -dependencies = [ - "libc", - "redox_users", - "winapi", -] - [[package]] name = "doc-comment" version = "0.3.3" @@ -767,15 +705,6 @@ version = "1.8.1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "7fcaabb2fef8c910e7f4c7ce9f67a1283a1715879a7c230ca9d6d1ae31f16d91" -[[package]] -name = "ena" -version = "0.14.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c533630cf40e9caa44bd91aadc88a75d75a4c3a12b4cfde353cbed41daa1e1f1" -dependencies = [ - "log", -] - [[package]] name = "encode_unicode" version = "0.3.6" @@ -833,15 +762,9 @@ dependencies = [ "windows-sys 0.48.0", ] -[[package]] -name = "fixedbitset" -version = "0.4.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0ce7134b9999ecaf8bcd65542e436736ef32ddca1b3e06094cb6ec5755203b80" - [[package]] name = "flake8-to-ruff" -version = "0.0.265" +version = "0.0.267" dependencies = [ "anyhow", "clap 4.2.4", @@ -918,7 +841,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "029d74589adefde59de1a0c4f4732695c32805624aec7b68d91503d4dba79afc" dependencies = [ "aho-corasick 0.7.20", - "bstr 1.4.0", + "bstr", "fnv", "log", "regex", @@ -1168,37 +1091,11 @@ dependencies = [ "libc", ] -[[package]] -name = "lalrpop" -version = "0.19.9" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f34313ec00c2eb5c3c87ca6732ea02dcf3af99c3ff7a8fb622ffb99c9d860a87" -dependencies = [ - "ascii-canvas", - "bit-set", - "diff", - "ena", - "is-terminal", - "itertools", - "lalrpop-util", - "petgraph", - "pico-args", - "regex", - "regex-syntax 0.6.29", - "string_cache", - "term", - "tiny-keccak", - "unicode-xid", -] - [[package]] name = "lalrpop-util" -version = "0.19.9" +version = "0.20.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e5c1f7869c94d214466c5fd432dfed12c379fd87786768d36455892d46b18edd" -dependencies = [ - "regex", -] +checksum = "3f35c735096c0293d313e8f2a641627472b83d01b937177fe76e5e2708d31e0d" [[package]] name = "lazy_static" @@ -1297,16 +1194,6 @@ version = "0.3.3" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "9b085a4f2cde5781fc4b1717f2e86c62f5cda49de7ba99a7c2eae02b61c9064c" -[[package]] -name = "lock_api" -version = "0.4.9" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "435011366fe56583b16cf956f9df0095b405b82d76425bc8981c0e22e60ec4df" -dependencies = [ - "autocfg", - "scopeguard", -] - [[package]] name = "log" version = "0.4.17" @@ -1316,15 +1203,6 @@ dependencies = [ "cfg-if", ] -[[package]] -name = "lz4_flex" -version = "0.9.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1a8cbbb2831780bc3b9c15a41f5b49222ef756b6730a95f3decfdd15903eb5a3" -dependencies = [ - "twox-hash", -] - [[package]] name = "matches" version = "0.1.10" @@ -1388,12 +1266,6 @@ version = "1.0.9" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "308d96db8debc727c3fd9744aac51751243420e46edf401010908da7f8d5e57c" -[[package]] -name = "new_debug_unreachable" -version = "1.0.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e4a24736216ec316047a1fc4252e27dabb04218aa4a3f37c6e7ddbf1f9782b54" - [[package]] name = "nextest-workspace-hack" version = "0.1.0" @@ -1457,15 +1329,6 @@ dependencies = [ "num-traits", ] -[[package]] -name = "num-complex" -version = "0.4.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "02e0d21255c828d6f128a1e41534206671e8c3ea0c62f32291e808dc82cff17d" -dependencies = [ - "num-traits", -] - [[package]] name = "num-integer" version = "0.1.45" @@ -1525,29 +1388,6 @@ dependencies = [ "winapi", ] -[[package]] -name = "parking_lot" -version = "0.12.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3742b2c103b9f06bc9fff0a37ff4912935851bee6d36f3c02bcc755bcfec228f" -dependencies = [ - "lock_api", - "parking_lot_core", -] - -[[package]] -name = "parking_lot_core" -version = "0.9.7" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9069cbb9f99e3a5083476ccb29ceb1de18b9118cafa53e90c9551235de2b9521" -dependencies = [ - "cfg-if", - "libc", - "redox_syscall 0.2.16", - "smallvec", - "windows-sys 0.45.0", -] - [[package]] name = "paste" version = "1.0.12" @@ -1624,23 +1464,13 @@ version = "2.2.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "478c572c3d73181ff3c2539045f6eb99e5491218eae919370993b890cdbdd98e" -[[package]] -name = "petgraph" -version = "0.6.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4dd7d28ee937e54fe3080c91faa1c3a46c06de6252988a7f4592ba2310ef22a4" -dependencies = [ - "fixedbitset", - "indexmap", -] - [[package]] name = "phf" version = "0.11.1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "928c6535de93548188ef63bb7c4036bd415cd8f36ad25af44b9789b2ee72a48c" dependencies = [ - "phf_shared 0.11.1", + "phf_shared", ] [[package]] @@ -1650,7 +1480,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "a56ac890c5e3ca598bbdeaa99964edb5b0258a583a9eb6ef4e89fc85d9224770" dependencies = [ "phf_generator", - "phf_shared 0.11.1", + "phf_shared", ] [[package]] @@ -1659,19 +1489,10 @@ version = "0.11.1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "b1181c94580fa345f50f19d738aaa39c0ed30a600d95cb2d3e23f94266f14fbf" dependencies = [ - "phf_shared 0.11.1", + "phf_shared", "rand", ] -[[package]] -name = "phf_shared" -version = "0.10.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b6796ad771acdc0123d2a88dc428b5e38ef24456743ddb1744ed628f9815c096" -dependencies = [ - "siphasher", -] - [[package]] name = "phf_shared" version = "0.11.1" @@ -1681,12 +1502,6 @@ dependencies = [ "siphasher", ] -[[package]] -name = "pico-args" -version = "0.4.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "db8bcd96cb740d03149cbad5518db9fd87126a10ab519c011893b1754134c468" - [[package]] name = "pin-project-lite" version = "0.2.9" @@ -1732,18 +1547,6 @@ dependencies = [ "syn 1.0.109", ] -[[package]] -name = "ppv-lite86" -version = "0.2.17" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5b40af805b3121feab8a3c29f04d8ad262fa8e0561883e7653e024ae4479e6de" - -[[package]] -name = "precomputed-hash" -version = "0.1.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "925383efa346730478fb4838dbe9137d2a47675ad789c546d150a6e1dd4ab31c" - [[package]] name = "predicates" version = "3.0.3" @@ -1849,30 +1652,12 @@ dependencies = [ "proc-macro2", ] -[[package]] -name = "radium" -version = "0.7.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "dc33ff2d4973d518d823d61aa239014831e521c75da58e3df4840d3f47749d09" - [[package]] name = "rand" version = "0.8.5" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "34af8d1a0e25924bc5b7c43c079c942339d8f0a8b57c39049bef581b46327404" dependencies = [ - "libc", - "rand_chacha", - "rand_core", -] - -[[package]] -name = "rand_chacha" -version = "0.3.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e6c10a63a0fa32252be49d21e7709d4d4baf8d231c2dbce1eaa8141b9b127d88" -dependencies = [ - "ppv-lite86", "rand_core", ] @@ -1881,9 +1666,6 @@ name = "rand_core" version = "0.6.4" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "ec0be4795e2f6a28069bec0b5ff3e2ac9bafc99e6a9a7dc3547996c5c816922c" -dependencies = [ - "getrandom", -] [[package]] name = "rayon" @@ -1944,7 +1726,7 @@ checksum = "af83e617f331cc6ae2da5443c602dfa5af81e517212d9d611a5b3ba1777b5370" dependencies = [ "aho-corasick 1.0.1", "memchr", - "regex-syntax 0.7.1", + "regex-syntax", ] [[package]] @@ -1953,12 +1735,6 @@ version = "0.1.10" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "6c230d73fb8d8c1b9c0b3135c5142a8acee3a0558fb8db5cf1cb65f8d7862132" -[[package]] -name = "regex-syntax" -version = "0.6.29" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f162c6dd7b008981e4d40210aca20b4bd0f9b60ca9271061b07f78537722f2e1" - [[package]] name = "regex-syntax" version = "0.7.1" @@ -2004,11 +1780,11 @@ dependencies = [ [[package]] name = "ruff" -version = "0.0.265" +version = "0.0.267" dependencies = [ "annotate-snippets 0.9.1", "anyhow", - "bitflags 2.1.0", + "bitflags 2.2.1", "chrono", "clap 4.2.4", "colored", @@ -2044,7 +1820,7 @@ dependencies = [ "ruff_rustpython", "ruff_text_size", "rustc-hash", - "rustpython-common", + "rustpython-format", "rustpython-parser", "schemars", "semver", @@ -2093,7 +1869,7 @@ dependencies = [ [[package]] name = "ruff_cli" -version = "0.0.265" +version = "0.0.267" dependencies = [ "annotate-snippets 0.9.1", "anyhow", @@ -2101,7 +1877,7 @@ dependencies = [ "assert_cmd", "atty", "bincode", - "bitflags 2.1.0", + "bitflags 2.2.1", "cachedir", "chrono", "clap 4.2.4", @@ -2151,7 +1927,7 @@ dependencies = [ "ruff", "ruff_cli", "ruff_diagnostics", - "rustpython-common", + "rustpython-format", "rustpython-parser", "schemars", "serde_json", @@ -2200,7 +1976,7 @@ name = "ruff_python_ast" version = "0.0.0" dependencies = [ "anyhow", - "bitflags 2.1.0", + "bitflags 2.2.1", "is-macro", "itertools", "log", @@ -2209,10 +1985,9 @@ dependencies = [ "num-traits", "once_cell", "regex", - "ruff_rustpython", "ruff_text_size", "rustc-hash", - "rustpython-common", + "rustpython-literal", "rustpython-parser", "serde", "smallvec", @@ -2234,7 +2009,6 @@ dependencies = [ "ruff_testing_macros", "ruff_text_size", "rustc-hash", - "rustpython-common", "rustpython-parser", "similar", "test-case", @@ -2244,7 +2018,7 @@ dependencies = [ name = "ruff_python_semantic" version = "0.0.0" dependencies = [ - "bitflags 2.1.0", + "bitflags 2.2.1", "is-macro", "nohash-hasher", "ruff_python_ast", @@ -2268,8 +2042,6 @@ name = "ruff_rustpython" version = "0.0.0" dependencies = [ "anyhow", - "once_cell", - "rustpython-common", "rustpython-parser", ] @@ -2286,7 +2058,7 @@ dependencies = [ [[package]] name = "ruff_text_size" version = "0.0.0" -source = "git+https://github.com/charliermarsh/RustPython.git?rev=c3147d2c1524ebd0e90cf1c2938d770314fd5a5a#c3147d2c1524ebd0e90cf1c2938d770314fd5a5a" +source = "git+https://github.com/RustPython/Parser.git?rev=a983f4383fb1ad8c1c66acb1d5b0016e59f95a49#a983f4383fb1ad8c1c66acb1d5b0016e59f95a49" dependencies = [ "schemars", "serde", @@ -2357,75 +2129,66 @@ dependencies = [ [[package]] name = "rustpython-ast" version = "0.2.0" -source = "git+https://github.com/charliermarsh/RustPython.git?rev=c3147d2c1524ebd0e90cf1c2938d770314fd5a5a#c3147d2c1524ebd0e90cf1c2938d770314fd5a5a" +source = "git+https://github.com/RustPython/Parser.git?rev=a983f4383fb1ad8c1c66acb1d5b0016e59f95a49#a983f4383fb1ad8c1c66acb1d5b0016e59f95a49" dependencies = [ + "is-macro", "num-bigint", - "ruff_text_size", + "rustpython-parser-core", ] [[package]] -name = "rustpython-common" +name = "rustpython-format" version = "0.2.0" -source = "git+https://github.com/charliermarsh/RustPython.git?rev=c3147d2c1524ebd0e90cf1c2938d770314fd5a5a#c3147d2c1524ebd0e90cf1c2938d770314fd5a5a" +source = "git+https://github.com/RustPython/Parser.git?rev=a983f4383fb1ad8c1c66acb1d5b0016e59f95a49#a983f4383fb1ad8c1c66acb1d5b0016e59f95a49" dependencies = [ - "ascii", - "bitflags 1.3.2", - "bstr 0.2.17", - "cfg-if", - "getrandom", - "hexf-parse", + "bitflags 2.2.1", "itertools", - "lexical-parse-float", - "libc", - "lock_api", "num-bigint", "num-traits", - "once_cell", - "radium", - "rand", - "siphasher", - "unic-ucd-category", - "volatile", - "widestring", + "rustpython-literal", ] [[package]] -name = "rustpython-compiler-core" +name = "rustpython-literal" version = "0.2.0" -source = "git+https://github.com/charliermarsh/RustPython.git?rev=c3147d2c1524ebd0e90cf1c2938d770314fd5a5a#c3147d2c1524ebd0e90cf1c2938d770314fd5a5a" +source = "git+https://github.com/RustPython/Parser.git?rev=a983f4383fb1ad8c1c66acb1d5b0016e59f95a49#a983f4383fb1ad8c1c66acb1d5b0016e59f95a49" dependencies = [ - "bitflags 1.3.2", - "itertools", - "lz4_flex", - "num-bigint", - "num-complex", - "ruff_text_size", + "hexf-parse", + "lexical-parse-float", + "num-traits", + "unic-ucd-category", ] [[package]] name = "rustpython-parser" version = "0.2.0" -source = "git+https://github.com/charliermarsh/RustPython.git?rev=c3147d2c1524ebd0e90cf1c2938d770314fd5a5a#c3147d2c1524ebd0e90cf1c2938d770314fd5a5a" +source = "git+https://github.com/RustPython/Parser.git?rev=a983f4383fb1ad8c1c66acb1d5b0016e59f95a49#a983f4383fb1ad8c1c66acb1d5b0016e59f95a49" dependencies = [ "anyhow", "itertools", - "lalrpop", "lalrpop-util", "log", "num-bigint", "num-traits", "phf", "phf_codegen", - "ruff_text_size", "rustc-hash", "rustpython-ast", - "rustpython-compiler-core", + "rustpython-parser-core", "tiny-keccak", "unic-emoji-char", "unic-ucd-ident", "unicode_names2", ] +[[package]] +name = "rustpython-parser-core" +version = "0.2.0" +source = "git+https://github.com/RustPython/Parser.git?rev=a983f4383fb1ad8c1c66acb1d5b0016e59f95a49#a983f4383fb1ad8c1c66acb1d5b0016e59f95a49" +dependencies = [ + "ruff_text_size", +] + [[package]] name = "rustversion" version = "1.0.12" @@ -2613,19 +2376,6 @@ version = "1.1.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "a2eb9349b6444b326872e140eb1cf5e7c522154d69e7a0ffb0fb81c06b37543f" -[[package]] -name = "string_cache" -version = "0.8.7" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f91138e76242f575eb1d3b38b4f1362f10d3a43f47d182a5b359af488a02293b" -dependencies = [ - "new_debug_unreachable", - "once_cell", - "parking_lot", - "phf_shared 0.10.0", - "precomputed-hash", -] - [[package]] name = "strsim" version = "0.10.0" @@ -2698,17 +2448,6 @@ dependencies = [ "windows-sys 0.45.0", ] -[[package]] -name = "term" -version = "0.7.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c59df8ac95d96ff9bede18eb7300b0fda5e5d8d90960e76f8e14ae765eedbf1f" -dependencies = [ - "dirs-next", - "rustversion", - "winapi", -] - [[package]] name = "termcolor" version = "1.2.0" @@ -2944,16 +2683,6 @@ dependencies = [ "once_cell", ] -[[package]] -name = "twox-hash" -version = "1.6.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "97fee6b57c6a41524a810daee9286c02d7752c4253064d0b05472833a438f675" -dependencies = [ - "cfg-if", - "static_assertions", -] - [[package]] name = "typed-arena" version = "2.0.2" @@ -3061,12 +2790,6 @@ version = "0.1.10" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "c0edd1e5b14653f783770bce4a4dabb4a5108a5370a5f5d8cfe8710c361f6c8b" -[[package]] -name = "unicode-xid" -version = "0.2.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f962df74c8c05a667b5ee8bcf162993134c104e96440b663c8daa176dc772d8c" - [[package]] name = "unicode_names2" version = "0.6.0" @@ -3126,12 +2849,6 @@ version = "0.9.4" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "49874b5167b65d7193b8aba1567f5c7d93d001cafc34600cee003eda787e483f" -[[package]] -name = "volatile" -version = "0.3.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f8e76fae08f03f96e166d2dfda232190638c10e0383841252416f9cfe2ae60e6" - [[package]] name = "wait-timeout" version = "0.2.0" @@ -3293,12 +3010,6 @@ dependencies = [ "once_cell", ] -[[package]] -name = "widestring" -version = "0.5.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "17882f045410753661207383517a6f62ec3dbeb6a4ed2acce01f0728238d1983" - [[package]] name = "wild" version = "2.1.0" diff --git a/pkgs/development/tools/ruff/default.nix b/pkgs/development/tools/ruff/default.nix index 1a41ce46c6f8..b1d4e87a4bfd 100644 --- a/pkgs/development/tools/ruff/default.nix +++ b/pkgs/development/tools/ruff/default.nix @@ -1,6 +1,7 @@ { lib , rustPlatform , fetchFromGitHub +, fetchpatch , installShellFiles , stdenv , darwin @@ -8,26 +9,37 @@ rustPlatform.buildRustPackage rec { pname = "ruff"; - version = "0.0.265"; + version = "0.0.267"; src = fetchFromGitHub { owner = "charliermarsh"; repo = pname; rev = "v${version}"; - hash = "sha256-b45kPvN2yILZBvP8eSNfWD6gpinwi9RsvmonRGYj0cI="; + hash = "sha256-inbW+oobW0hAsNdvJoiHvKoKAUjcuhEUrJe7fh5c6go="; }; - # We have to use importCargoLock here because `cargo vendor` currently doesn't support workspace - # inheritance within Git dependencies, but importCargoLock does. cargoLock = { lockFile = ./Cargo.lock; outputHashes = { "libcst-0.1.0" = "sha256-jG9jYJP4reACkFLrQBWOYH6nbKniNyFVItD0cTZ+nW0="; - "ruff_text_size-0.0.0" = "sha256-+pAsfjJfN6899zIv2sj2gMyCuR8m/Ko928ZUw+X6u7Y="; + "ruff_text_size-0.0.0" = "sha256-rOk7N6YyMDiC/mn60Q5b3JGFvclj4ICbhYlpwNQsOiI="; + "rustpython-literal-0.2.0" = "sha256-GBlD+oZpUxciPcBMw5Qq1sJoZqs4RwjZ+W53M3CqdAc="; "unicode_names2-0.6.0" = "sha256-eWg9+ISm/vztB0KIdjhq5il2ZnwGJQCleCYfznCI3Wg="; }; }; + patches = [ + # without this patch, cargo-vendor-dir fails with the following error: + # ln: failed to create symbolic link '...-rustpython-literal-0.2.0': Permission denied + # this patch removes dependencies with the same name and fixes the conflict + # https://github.com/charliermarsh/ruff/pull/4388 + (fetchpatch { + name = "use-new-rustpython-format-crate-over-rustpython-common.patch"; + url = "https://github.com/charliermarsh/ruff/commit/10eb4a38e86449fae023fbb591ffc16efec85bc8.patch"; + hash = "sha256-bIun+Ge0bh4te0ih3bQtwRWJGi1h0weiLaN1AOhXR6E="; + }) + ]; + nativeBuildInputs = [ installShellFiles ];