mirror of
https://github.com/NixOS/nixpkgs.git
synced 2025-02-13 15:43:39 +00:00
python311Packages.python-lsp-black: fix tests for black 24.3.0+ (#303044)
fixes https://github.com/NixOS/nixpkgs/issues/302902 also makes the patches fail explicitly when not needed anymore Co-authored-by: Jörg Thalheim <Mic92@users.noreply.github.com> Co-authored-by: Dixon Sean Low Yan Feng <dixonseanlow@protonmail.com>
This commit is contained in:
parent
8d36569446
commit
cd0f818f2e
@ -24,15 +24,20 @@ buildPythonPackage rec {
|
|||||||
};
|
};
|
||||||
|
|
||||||
patches =
|
patches =
|
||||||
/** fix test failure with black<24.2.0;
|
/** includes a series of patches fixing tests not yet released as 2.0.1+ version
|
||||||
remove this patch once python-lsp-black>2.0.0 */
|
they are meant to keep up to date with black releases */
|
||||||
lib.optional
|
lib.optional
|
||||||
(with lib; (versionOlder version "2.0.1") && (versionAtLeast black.version "24.2.0"))
|
(with lib; versionAtLeast black.version "24.2.0")
|
||||||
(fetchpatch {
|
(fetchpatch {
|
||||||
url = "https://patch-diff.githubusercontent.com/raw/python-lsp/python-lsp-black/pull/56.patch";
|
url = "https://github.com/python-lsp/python-lsp-black/commit/d43b41431379f9c9bb05fab158c4d97e6d515f8f.patch";
|
||||||
hash = "sha256-38bYU27+xtA8Kq3appXTkNnkG5/XgrUJ2nQ5+yuSU2U=";
|
hash = "sha256-38bYU27+xtA8Kq3appXTkNnkG5/XgrUJ2nQ5+yuSU2U=";
|
||||||
})
|
})
|
||||||
++ [ ];
|
++ lib.optional
|
||||||
|
(with lib; versionAtLeast black.version "24.3.0")
|
||||||
|
(fetchpatch {
|
||||||
|
url = "https://github.com/python-lsp/python-lsp-black/commit/9298585a9d14d25920c33b188d79e820dc98d4a9.patch";
|
||||||
|
hash = "sha256-4u0VIS7eidVEiKRW2wc8lJVkJwhzJD/M+uuqmTtiZ7E=";
|
||||||
|
});
|
||||||
|
|
||||||
nativeBuildInputs = [
|
nativeBuildInputs = [
|
||||||
setuptools
|
setuptools
|
||||||
|
Loading…
Reference in New Issue
Block a user