From de7d13b0e8dea4affd1ff40ff4d9ae62b27f3af0 Mon Sep 17 00:00:00 2001 From: "Adam J. Stewart" Date: Wed, 16 May 2018 22:54:33 -0500 Subject: Add dependencies for py-dask (#8120) --- .../repos/builtin/packages/py-attrs/package.py | 16 +++++-- .../builtin/packages/py-cloudpickle/package.py | 42 +++++++++++++++++ .../repos/builtin/packages/py-dask/package.py | 55 ++++++++++++++++++++-- .../repos/builtin/packages/py-locket/package.py | 36 ++++++++++++++ .../repos/builtin/packages/py-partd/package.py | 40 ++++++++++++++++ .../repos/builtin/packages/py-pluggy/package.py | 40 ++++++++++++++++ var/spack/repos/builtin/packages/py-py/package.py | 7 ++- .../repos/builtin/packages/py-pytest/package.py | 22 +++++---- .../repos/builtin/packages/py-toolz/package.py | 38 +++++++++++++++ .../builtin/packages/py-zope-event/package.py | 40 ++++++++++++++++ .../builtin/packages/py-zope-interface/package.py | 48 +++++++++++++++++++ 11 files changed, 367 insertions(+), 17 deletions(-) create mode 100644 var/spack/repos/builtin/packages/py-cloudpickle/package.py create mode 100644 var/spack/repos/builtin/packages/py-locket/package.py create mode 100644 var/spack/repos/builtin/packages/py-partd/package.py create mode 100644 var/spack/repos/builtin/packages/py-pluggy/package.py create mode 100644 var/spack/repos/builtin/packages/py-toolz/package.py create mode 100644 var/spack/repos/builtin/packages/py-zope-event/package.py create mode 100644 var/spack/repos/builtin/packages/py-zope-interface/package.py (limited to 'var') diff --git a/var/spack/repos/builtin/packages/py-attrs/package.py b/var/spack/repos/builtin/packages/py-attrs/package.py index c3091c9e12..074b7fc29e 100644 --- a/var/spack/repos/builtin/packages/py-attrs/package.py +++ b/var/spack/repos/builtin/packages/py-attrs/package.py @@ -26,11 +26,21 @@ from spack import * class PyAttrs(PythonPackage): - """Python Attributes Without Boilerplate""" + """Classes Without Boilerplate""" homepage = "http://attrs.org/" - url = "https://pypi.io/packages/source/a/attrs/attrs-16.3.0.tar.gz" + url = "https://pypi.io/packages/source/a/attrs/attrs-18.1.0.tar.gz" + import_modules = ['attr'] + + version('18.1.0', '3f3f3e0750dab74cfa1dc8b0fd7a5f86') version('16.3.0', '4ec003c49360853cf935113d1ae56151') - depends_on('py-setuptools', type='build') + depends_on('py-setuptools', type='build') + + depends_on('py-coverage', type='test') + depends_on('py-hypothesis', type='test') + depends_on('py-pympler', type='test') + depends_on('py-pytest', type='test') + depends_on('py-six', type='test') + depends_on('py-zope-interface', type='test') diff --git a/var/spack/repos/builtin/packages/py-cloudpickle/package.py b/var/spack/repos/builtin/packages/py-cloudpickle/package.py new file mode 100644 index 0000000000..f4a22c0f7c --- /dev/null +++ b/var/spack/repos/builtin/packages/py-cloudpickle/package.py @@ -0,0 +1,42 @@ +############################################################################## +# Copyright (c) 2013-2018, Lawrence Livermore National Security, LLC. +# Produced at the Lawrence Livermore National Laboratory. +# +# This file is part of Spack. +# Created by Todd Gamblin, tgamblin@llnl.gov, All rights reserved. +# LLNL-CODE-647188 +# +# For details, see https://github.com/spack/spack +# Please also see the NOTICE and LICENSE files for our notice and the LGPL. +# +# This program is free software; you can redistribute it and/or modify +# it under the terms of the GNU Lesser General Public License (as +# published by the Free Software Foundation) version 2.1, February 1999. +# +# This program is distributed in the hope that it will be useful, but +# WITHOUT ANY WARRANTY; without even the IMPLIED WARRANTY OF +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the terms and +# conditions of the GNU Lesser General Public License for more details. +# +# You should have received a copy of the GNU Lesser General Public +# License along with this program; if not, write to the Free Software +# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA +############################################################################## +from spack import * + + +class PyCloudpickle(PythonPackage): + """Extended pickling support for Python objects.""" + + homepage = "https://github.com/cloudpipe/cloudpickle" + url = "https://pypi.io/packages/source/c/cloudpickle/cloudpickle-0.5.2.tar.gz" + + import_modules = ['cloudpickle'] + + version('0.5.2', 'd0f6fc27882f865f2eb185fb0a32c84b') + + depends_on('py-setuptools', type='build') + + def test(self): + # PyPI tarball does not come with unit tests + pass diff --git a/var/spack/repos/builtin/packages/py-dask/package.py b/var/spack/repos/builtin/packages/py-dask/package.py index 485ae9addc..f956efcc6c 100644 --- a/var/spack/repos/builtin/packages/py-dask/package.py +++ b/var/spack/repos/builtin/packages/py-dask/package.py @@ -26,10 +26,57 @@ from spack import * class PyDask(PythonPackage): - """Minimal task scheduling abstraction""" + """Dask is a flexible parallel computing library for analytics.""" + homepage = "https://github.com/dask/dask/" - url = "https://pypi.io/packages/source/d/dask/dask-0.8.1.tar.gz" + url = "https://pypi.io/packages/source/d/dask/dask-0.17.4.tar.gz" + + version('0.17.4', '4a7b9c5d7ddf52639b1c6b9e8a68d146') + version('0.8.1', '5dd8e3a3823b3bc62c9a6d192e2cb5b4') + + variant('array', default=True, description='Install requirements for dask.array') + variant('bag', default=True, description='Install requirements for dask.bag') + variant('dataframe', default=True, description='Install requirements for dask.dataframe') + variant('delayed', default=True, description='Install requirements for dask.delayed') + + depends_on('py-setuptools', type='build') + depends_on('py-pytest@3.1.0:', type='test') + depends_on('py-requests', type='test') + + # Requirements for dask.array + depends_on('py-numpy@1.11.0:', type=('build', 'run'), when='+array') + depends_on('py-toolz@0.7.3:', type=('build', 'run'), when='+array') + + # Requirements for dask.bag + depends_on('py-cloudpickle@0.2.1:', type=('build', 'run'), when='+bag') + depends_on('py-toolz@0.7.3:', type=('build', 'run'), when='+bag') + depends_on('py-partd@0.3.8:', type=('build', 'run'), when='+bag') + + # Requirements for dask.dataframe + depends_on('py-numpy@1.11.0:', type=('build', 'run'), when='+dataframe') + depends_on('py-pandas@0.19.0:', type=('build', 'run'), when='+dataframe') + depends_on('py-toolz@0.7.3:', type=('build', 'run'), when='+dataframe') + depends_on('py-partd@0.3.8:', type=('build', 'run'), when='+dataframe') + depends_on('py-cloudpickle@0.2.1:', type=('build', 'run'), when='+dataframe') + + # Requirements for dask.delayed + depends_on('py-toolz@0.7.3:', type=('build', 'run'), when='+delayed') + + @property + def import_modules(self): + modules = [ + 'dask', 'dask.bytes', 'dask.diagnostics', 'dask.store' + ] + + if '+array' in self.spec: + modules.append('dask.array') + + if '+bag' in self.spec: + modules.append('dask.bag') - version('0.8.1', '5dd8e3a3823b3bc62c9a6d192e2cb5b4') + if '+dataframe' in self.spec: + modules.extend([ + 'dask.dataframe', 'dask.dataframe.io', 'dask.dataframe.tseries' + ]) - depends_on('py-setuptools', type='build') + return modules diff --git a/var/spack/repos/builtin/packages/py-locket/package.py b/var/spack/repos/builtin/packages/py-locket/package.py new file mode 100644 index 0000000000..dfe683a4b0 --- /dev/null +++ b/var/spack/repos/builtin/packages/py-locket/package.py @@ -0,0 +1,36 @@ +############################################################################## +# Copyright (c) 2013-2018, Lawrence Livermore National Security, LLC. +# Produced at the Lawrence Livermore National Laboratory. +# +# This file is part of Spack. +# Created by Todd Gamblin, tgamblin@llnl.gov, All rights reserved. +# LLNL-CODE-647188 +# +# For details, see https://github.com/spack/spack +# Please also see the NOTICE and LICENSE files for our notice and the LGPL. +# +# This program is free software; you can redistribute it and/or modify +# it under the terms of the GNU Lesser General Public License (as +# published by the Free Software Foundation) version 2.1, February 1999. +# +# This program is distributed in the hope that it will be useful, but +# WITHOUT ANY WARRANTY; without even the IMPLIED WARRANTY OF +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the terms and +# conditions of the GNU Lesser General Public License for more details. +# +# You should have received a copy of the GNU Lesser General Public +# License along with this program; if not, write to the Free Software +# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA +############################################################################## +from spack import * + + +class PyLocket(PythonPackage): + """File-based locks for Python for Linux and Windows.""" + + homepage = "http://github.com/mwilliamson/locket.py" + url = "https://pypi.io/packages/source/l/locket/locket-0.2.0.tar.gz" + + import_modules = ['locket'] + + version('0.2.0', 'fe870949c513d8f7079ba352463833ca') diff --git a/var/spack/repos/builtin/packages/py-partd/package.py b/var/spack/repos/builtin/packages/py-partd/package.py new file mode 100644 index 0000000000..f80537c7fa --- /dev/null +++ b/var/spack/repos/builtin/packages/py-partd/package.py @@ -0,0 +1,40 @@ +############################################################################## +# Copyright (c) 2013-2018, Lawrence Livermore National Security, LLC. +# Produced at the Lawrence Livermore National Laboratory. +# +# This file is part of Spack. +# Created by Todd Gamblin, tgamblin@llnl.gov, All rights reserved. +# LLNL-CODE-647188 +# +# For details, see https://github.com/spack/spack +# Please also see the NOTICE and LICENSE files for our notice and the LGPL. +# +# This program is free software; you can redistribute it and/or modify +# it under the terms of the GNU Lesser General Public License (as +# published by the Free Software Foundation) version 2.1, February 1999. +# +# This program is distributed in the hope that it will be useful, but +# WITHOUT ANY WARRANTY; without even the IMPLIED WARRANTY OF +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the terms and +# conditions of the GNU Lesser General Public License for more details. +# +# You should have received a copy of the GNU Lesser General Public +# License along with this program; if not, write to the Free Software +# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA +############################################################################## +from spack import * + + +class PyPartd(PythonPackage): + """Key-value byte store with appendable values.""" + + homepage = "http://github.com/dask/partd/" + url = "https://pypi.io/packages/source/p/partd/partd-0.3.8.tar.gz" + + import_modules = ['partd'] + + version('0.3.8', '554d0e6511c0df4c907f034858be847f') + + depends_on('py-setuptools', type='build') + depends_on('py-locket', type=('build', 'run')) + depends_on('py-toolz', type=('build', 'run')) diff --git a/var/spack/repos/builtin/packages/py-pluggy/package.py b/var/spack/repos/builtin/packages/py-pluggy/package.py new file mode 100644 index 0000000000..6e77c7a8f2 --- /dev/null +++ b/var/spack/repos/builtin/packages/py-pluggy/package.py @@ -0,0 +1,40 @@ +############################################################################## +# Copyright (c) 2013-2018, Lawrence Livermore National Security, LLC. +# Produced at the Lawrence Livermore National Laboratory. +# +# This file is part of Spack. +# Created by Todd Gamblin, tgamblin@llnl.gov, All rights reserved. +# LLNL-CODE-647188 +# +# For details, see https://github.com/spack/spack +# Please also see the NOTICE and LICENSE files for our notice and the LGPL. +# +# This program is free software; you can redistribute it and/or modify +# it under the terms of the GNU Lesser General Public License (as +# published by the Free Software Foundation) version 2.1, February 1999. +# +# This program is distributed in the hope that it will be useful, but +# WITHOUT ANY WARRANTY; without even the IMPLIED WARRANTY OF +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the terms and +# conditions of the GNU Lesser General Public License for more details. +# +# You should have received a copy of the GNU Lesser General Public +# License along with this program; if not, write to the Free Software +# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA +############################################################################## +from spack import * + + +class PyPluggy(PythonPackage): + """Plugin and hook calling mechanisms for python.""" + + homepage = "https://github.com/pytest-dev/pluggy" + url = "https://pypi.io/packages/source/p/pluggy/pluggy-0.6.0.tar.gz" + + import_modules = ['pluggy'] + + version('0.6.0', 'ffdde7c3a5ba9a440404570366ffb6d5') + + depends_on('python@2.7:2.8,3.4:', type=('build', 'run')) + + depends_on('py-setuptools', type='build') diff --git a/var/spack/repos/builtin/packages/py-py/package.py b/var/spack/repos/builtin/packages/py-py/package.py index 0c6bd8ecac..f585c84616 100644 --- a/var/spack/repos/builtin/packages/py-py/package.py +++ b/var/spack/repos/builtin/packages/py-py/package.py @@ -26,16 +26,19 @@ from spack import * class PyPy(PythonPackage): - """library with cross-python path, ini-parsing, io, code, log facilities""" + """Library with cross-python path, ini-parsing, io, code, log facilities""" homepage = "http://pylib.readthedocs.io/en/latest/" - url = "https://pypi.io/packages/source/p/py/py-1.4.33.tar.gz" + url = "https://pypi.io/packages/source/p/py/py-1.5.3.tar.gz" import_modules = [ 'py', 'py._code', 'py._io', 'py._log', 'py._path', 'py._process', ] + version('1.5.3', '667d37a148ad9fb81266492903f2d880') version('1.4.33', '15d7107cbb8b86593bf9afa16e56da65') version('1.4.31', '5d2c63c56dc3f2115ec35c066ecd582b') + depends_on('python@2.7:2.8,3.4:', type=('build', 'run')) + depends_on('py-setuptools', type='build') diff --git a/var/spack/repos/builtin/packages/py-pytest/package.py b/var/spack/repos/builtin/packages/py-pytest/package.py index 30aa0972d0..d41a19c432 100644 --- a/var/spack/repos/builtin/packages/py-pytest/package.py +++ b/var/spack/repos/builtin/packages/py-pytest/package.py @@ -29,23 +29,29 @@ class PyPytest(PythonPackage): """pytest: simple powerful testing with Python.""" homepage = "http://pytest.org/" - url = "https://pypi.io/packages/source/p/pytest/pytest-3.0.7.tar.gz" + url = "https://pypi.io/packages/source/p/pytest/pytest-3.5.1.tar.gz" import_modules = [ '_pytest', '_pytest.assertion', '_pytest._code', - '_pytest.vendored_packages', 'pytest' + '_pytest.mark', 'pytest' ] + version('3.5.1', 'ffd870ee3ca561695d2f916f0f0f3c0b') version('3.0.7', '89c60546507dc7eb6e9e40a6e9f720bd') version('3.0.2', '61dc36e65a6f6c11c53b1388e043a9f5') + depends_on('python@2.7:2.8,3.4:', type=('build', 'run')) + # Most Python packages only require setuptools as a build dependency. # However, pytest requires setuptools during runtime as well. depends_on('py-setuptools', type=('build', 'run')) - depends_on('py-py@1.4.29:', type=('build', 'run')) - depends_on('py-hypothesis@3.5.2:', type=('build', 'run')) + depends_on('py-py@1.5.0:', type=('build', 'run')) + depends_on('py-six@1.10.0:', type=('build', 'run')) + depends_on('py-attrs@17.4.0:', type=('build', 'run')) + depends_on('py-more-itertools@4.0.0:', type=('build', 'run')) + depends_on('py-pluggy@0.5:0.6', type=('build', 'run')) + depends_on('py-funcsigs', type=('build', 'run'), when='^python@:2') - # TODO: Add a 'test' deptype - # depends_on('py-nose', type='test') - # depends_on('py-mock', type='test') - # depends_on('py-requests', type='test') + depends_on('py-nose', type='test') + depends_on('py-mock', type='test') + depends_on('py-requests', type='test') diff --git a/var/spack/repos/builtin/packages/py-toolz/package.py b/var/spack/repos/builtin/packages/py-toolz/package.py new file mode 100644 index 0000000000..45305af961 --- /dev/null +++ b/var/spack/repos/builtin/packages/py-toolz/package.py @@ -0,0 +1,38 @@ +############################################################################## +# Copyright (c) 2013-2018, Lawrence Livermore National Security, LLC. +# Produced at the Lawrence Livermore National Laboratory. +# +# This file is part of Spack. +# Created by Todd Gamblin, tgamblin@llnl.gov, All rights reserved. +# LLNL-CODE-647188 +# +# For details, see https://github.com/spack/spack +# Please also see the NOTICE and LICENSE files for our notice and the LGPL. +# +# This program is free software; you can redistribute it and/or modify +# it under the terms of the GNU Lesser General Public License (as +# published by the Free Software Foundation) version 2.1, February 1999. +# +# This program is distributed in the hope that it will be useful, but +# WITHOUT ANY WARRANTY; without even the IMPLIED WARRANTY OF +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the terms and +# conditions of the GNU Lesser General Public License for more details. +# +# You should have received a copy of the GNU Lesser General Public +# License along with this program; if not, write to the Free Software +# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA +############################################################################## +from spack import * + + +class PyToolz(PythonPackage): + """A set of utility functions for iterators, functions, and dictionaries""" + + homepage = "http://github.com/pytoolz/toolz/" + url = "https://pypi.io/packages/source/t/toolz/toolz-0.9.0.tar.gz" + + import_modules = ['toolz', 'tlz', 'toolz.curried', 'toolz.sandbox'] + + version('0.9.0', '6fd07249389dd0b3bfe71d4282314328') + + depends_on('py-setuptools', type='build') diff --git a/var/spack/repos/builtin/packages/py-zope-event/package.py b/var/spack/repos/builtin/packages/py-zope-event/package.py new file mode 100644 index 0000000000..ab017b3d02 --- /dev/null +++ b/var/spack/repos/builtin/packages/py-zope-event/package.py @@ -0,0 +1,40 @@ +############################################################################## +# Copyright (c) 2013-2018, Lawrence Livermore National Security, LLC. +# Produced at the Lawrence Livermore National Laboratory. +# +# This file is part of Spack. +# Created by Todd Gamblin, tgamblin@llnl.gov, All rights reserved. +# LLNL-CODE-647188 +# +# For details, see https://github.com/spack/spack +# Please also see the NOTICE and LICENSE files for our notice and the LGPL. +# +# This program is free software; you can redistribute it and/or modify +# it under the terms of the GNU Lesser General Public License (as +# published by the Free Software Foundation) version 2.1, February 1999. +# +# This program is distributed in the hope that it will be useful, but +# WITHOUT ANY WARRANTY; without even the IMPLIED WARRANTY OF +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the terms and +# conditions of the GNU Lesser General Public License for more details. +# +# You should have received a copy of the GNU Lesser General Public +# License along with this program; if not, write to the Free Software +# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA +############################################################################## +from spack import * + + +class PyZopeEvent(PythonPackage): + """Very basic event publishing system.""" + + homepage = "http://github.com/zopefoundation/zope.event" + url = "https://pypi.io/packages/source/z/zope.event/zope.event-4.3.0.tar.gz" + + # FIXME: No idea why this import test fails. + # Maybe some kind of namespace issue? + # import_modules = ['zope.event'] + + version('4.3.0', '8ca737960741c6fd112972f3313303bd') + + depends_on('py-setuptools', type='build') diff --git a/var/spack/repos/builtin/packages/py-zope-interface/package.py b/var/spack/repos/builtin/packages/py-zope-interface/package.py new file mode 100644 index 0000000000..001ba23f3d --- /dev/null +++ b/var/spack/repos/builtin/packages/py-zope-interface/package.py @@ -0,0 +1,48 @@ +############################################################################## +# Copyright (c) 2013-2018, Lawrence Livermore National Security, LLC. +# Produced at the Lawrence Livermore National Laboratory. +# +# This file is part of Spack. +# Created by Todd Gamblin, tgamblin@llnl.gov, All rights reserved. +# LLNL-CODE-647188 +# +# For details, see https://github.com/spack/spack +# Please also see the NOTICE and LICENSE files for our notice and the LGPL. +# +# This program is free software; you can redistribute it and/or modify +# it under the terms of the GNU Lesser General Public License (as +# published by the Free Software Foundation) version 2.1, February 1999. +# +# This program is distributed in the hope that it will be useful, but +# WITHOUT ANY WARRANTY; without even the IMPLIED WARRANTY OF +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the terms and +# conditions of the GNU Lesser General Public License for more details. +# +# You should have received a copy of the GNU Lesser General Public +# License along with this program; if not, write to the Free Software +# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA +############################################################################## +from spack import * + + +class PyZopeInterface(PythonPackage): + """This package provides an implementation of "object interfaces" for + Python. Interfaces are a mechanism for labeling objects as conforming to a + given API or contract. So, this package can be considered as implementation + of the Design By Contract methodology support in Python.""" + + homepage = "https://github.com/zopefoundation/zope.interface" + url = "https://pypi.io/packages/source/z/zope.interface/zope.interface-4.5.0.tar.gz" + + # FIXME: No idea why these import tests fail. + # Maybe some kind of namespace issue? + # import_modules = ['zope.interface', 'zope.interface.common'] + + version('4.5.0', '7b669cd692d817772c61d2e3ad0f1e71') + + depends_on('python@2.7:2.8,3.4:', type=('build', 'run')) + + depends_on('py-setuptools', type='build') + depends_on('py-zope-event', type='test') + depends_on('py-nose', type='test') + depends_on('py-coverage', type='test') -- cgit v1.2.3-70-g09d2