Skip to content

Commit

Permalink
pythonPackages.libcst: init at 0.3.12
Browse files Browse the repository at this point in the history
I am adding this package because it is a dependency of
google_cloud_dataproc.
  • Loading branch information
ruuda committed Oct 11, 2020
1 parent 1467c16 commit 7911f87
Show file tree
Hide file tree
Showing 2 changed files with 38 additions and 0 deletions.
36 changes: 36 additions & 0 deletions pkgs/development/python-modules/libcst/default.nix
@@ -0,0 +1,36 @@
{ stdenv
, buildPythonPackage
, fetchPypi
, typing-inspect
, pyyaml
, isPy3k
}:

buildPythonPackage rec {
pname = "libcst";
version = "0.3.12";

src = fetchPypi {
inherit pname version;
sha256 = "1zgwxdbhz2ljl0yzbrn1f4f464rjphx0j6r4qq0csax3m4wp50x1";
};

# The library uses type annotation syntax.
disabled = !isPy3k;

propagatedBuildInputs = [ typing-inspect pyyaml ];

# Test fails with ValueError: No data_provider tests were created for
# test_type_availability! Please double check your data.
# The tests appear to be doing some dynamic introspection, not sure what is
# going on there.
doCheck = false;
pythonImportsCheck = [ "libcst" ];

meta = with stdenv.lib; {
description = "A concrete syntax tree parser and serializer library for Python that preserves many aspects of Python's abstract syntax tree";
homepage = "https://libcst.readthedocs.io/en/latest/";
license = with licenses; [mit asl20 psfl];
maintainers = [ maintainers.ruuda ];
};
}
2 changes: 2 additions & 0 deletions pkgs/top-level/python-packages.nix
Expand Up @@ -3275,6 +3275,8 @@ in {
else
callPackage ../development/python-modules/libcloud { };

libcst = callPackage ../development/python-modules/libcst { };

libevdev = callPackage ../development/python-modules/libevdev { };

libfdt = toPythonModule (pkgs.dtc.override {
Expand Down

0 comments on commit 7911f87

Please sign in to comment.