mirror of
https://github.com/NixOS/nixpkgs.git
synced 2025-01-21 04:13:12 +00:00
gast: patch 0.5.0 to fix NamedExpr parsing (#131237)
Co-authored-by: Sandro <sandro.jaeckel@gmail.com>
This commit is contained in:
parent
f7e77f65ee
commit
4b4a07e868
@ -1,16 +1,36 @@
|
||||
{ lib, fetchPypi, buildPythonPackage, astunparse }:
|
||||
{ lib
|
||||
, fetchFromGitHub
|
||||
, fetchpatch
|
||||
, buildPythonPackage
|
||||
, astunparse
|
||||
}:
|
||||
|
||||
buildPythonPackage rec {
|
||||
pname = "gast";
|
||||
version = "0.5.0";
|
||||
src = fetchPypi {
|
||||
inherit pname version;
|
||||
sha256 = "8109cbe7aa0f7bf7e4348379da05b8137ea1f059f073332c3c1cedd57db8541f";
|
||||
version = "0.5.0";
|
||||
|
||||
# TODO: remove this patch on the next release, this fixes a bug with parsing
|
||||
# assignment expressions e.g., `x := 1`.
|
||||
patches = [
|
||||
(fetchpatch {
|
||||
url = "https://github.com/serge-sans-paille/gast/commit/3cc9b4d05a80e4bb42882de00df314aaa1e6e591.patch";
|
||||
sha256 = "0ylpn0x0a4y6139vd048blsh77yd08npjcn4b5ydf89xnji5mlm1";
|
||||
})
|
||||
];
|
||||
|
||||
src = fetchFromGitHub {
|
||||
owner = "serge-sans-paille";
|
||||
repo = "gast";
|
||||
rev = version;
|
||||
sha256 = "0qsg36knv0k2ppzbr5m4w6spxxw7a77lw88y8vjx7m176bajnsbw";
|
||||
};
|
||||
checkInputs = [ astunparse ] ;
|
||||
|
||||
checkInputs = [ astunparse ];
|
||||
|
||||
meta = with lib; {
|
||||
description = "GAST provides a compatibility layer between the AST of various Python versions, as produced by ast.parse from the standard ast module.";
|
||||
homepage = "https://github.com/serge-sans-paille/gast/";
|
||||
license = licenses.bsd3;
|
||||
maintainers = with maintainers; [ jyp ];
|
||||
maintainers = with maintainers; [ jyp cpcloud ];
|
||||
};
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user