Carl Smedstad pushed to branch main at Arch Linux / Packaging / Packages / 
python-fastparquet


Commits:
6f804976 by Carl Smedstad at 2024-04-28T00:07:40+02:00
Add .nvchecker.toml

- - - - -
46958d1c by Carl Smedstad at 2024-05-12T16:30:36+02:00
Adopt & add testing

- - - - -


2 changed files:

- + .nvchecker.toml
- PKGBUILD


Changes:

=====================================
.nvchecker.toml
=====================================
@@ -0,0 +1,3 @@
+[python-fastparquet]
+source = "pypi"
+pypi = "fastparquet"


=====================================
PKGBUILD
=====================================
@@ -1,26 +1,64 @@
-# Maintainer:
+# Maintainer: Carl Smedstad <car...@archlinux.org>
 # Contributor: Guillaume Horel <guillaume.ho...@gmail.com>
 
-_pyname=fastparquet
-pkgname=python-$_pyname
+pkgname=python-fastparquet
+_pkgname=${pkgname#python-}
 pkgver=2024.2.0
-pkgrel=2
-pkgdesc='A python implementation of the parquet format'
-url='https://github.com/dask/fastparquet'
-depends=(python python-cramjam python-pandas python-fsspec)
-makedepends=(cython python-build python-installer python-setuptools 
python-wheel python-numpy git)
-optdepends=(python-s3fs)
-license=(Apache-2.0)
+pkgrel=3
+pkgdesc="A Python implementation of the Parquet columnar file format"
 arch=(x86_64)
-source=(https://github.com/dask/fastparquet/archive/$pkgver/$pkgname-$pkgver.tar.gz)
+url="https://github.com/dask/fastparquet";
+license=(Apache-2.0)
+depends=(
+  glibc
+  python
+  python-cramjam
+  python-fsspec
+  python-numpy
+  python-packaging
+  python-pandas
+)
+makedepends=(
+  cython
+  git
+  python-build
+  python-installer
+  python-setuptools
+  python-setuptools-scm
+  python-wheel
+)
+checkdepends=(python-pytest)
+source=("$pkgname-$pkgver.tar.gz::$url/archive/$pkgver.tar.gz")
 sha256sums=('b747ec949616dfd76b7d3f2fa793a3f4ab6271040aca89d656ee41db056cddc0')
 
+_archive="$_pkgname-$pkgver"
+
+prepare() {
+  cd "$_archive"
+
+  # Move tests out of the package, will not work with the tmp_install method
+  # in check() otherwise.
+  mv fastparquet/test/ tests/
+}
+
 build() {
-  cd $_pyname-$pkgver
+  cd "$_archive"
+
+  export SETUPTOOLS_SCM_PRETEND_VERSION=$pkgver
   python -m build --wheel --no-isolation --skip-dependency-check
 }
 
+check() {
+  cd "$_archive"
+
+  python -m installer --destdir=tmp_install dist/*.whl
+  local site_packages=$(python -c "import site; 
print(site.getsitepackages()[0])")
+  export PYTHONPATH="$PWD/tmp_install/$site_packages:."
+  pytest --import-mode=importlib
+}
+
 package() {
-  cd $_pyname-$pkgver
+  cd "$_archive"
+
   python -m installer --destdir="$pkgdir" dist/*.whl
 }



View it on GitLab: 
https://gitlab.archlinux.org/archlinux/packaging/packages/python-fastparquet/-/compare/ef8c7ab19b05f3810e9973b6586ee76ba69c05e5...46958d1c894887c2daf7a8a2b4bba93303775e46

-- 
This project does not include diff previews in email notifications.
View it on GitLab: 
https://gitlab.archlinux.org/archlinux/packaging/packages/python-fastparquet/-/compare/ef8c7ab19b05f3810e9973b6586ee76ba69c05e5...46958d1c894887c2daf7a8a2b4bba93303775e46
You're receiving this email because of your account on gitlab.archlinux.org.


Reply via email to