summarylogtreecommitdiffstats
diff options
context:
space:
mode:
authorBert Peters2024-03-31 22:28:22 +0200
committerBert Peters2024-03-31 22:31:35 +0200
commit8cde4abb9098f287d4e1e6261729e8f78b44e9fc (patch)
treed892670bac1da6d4f6291555bdb979812a1429c3
parent8181982ae32e846a4c956a691ce4eb271d2885c6 (diff)
downloadaur-8cde4abb9098f287d4e1e6261729e8f78b44e9fc.tar.gz
upgpkg: python-plotly 5.20.0-2
Rework sources as a git package rather than relying on tarballs, which have repeatedly changed checksums for unknown reasons.
-rw-r--r--.SRCINFO13
-rw-r--r--PKGBUILD69
2 files changed, 47 insertions, 35 deletions
diff --git a/.SRCINFO b/.SRCINFO
index b17a43fd6432..dfd7fa82d637 100644
--- a/.SRCINFO
+++ b/.SRCINFO
@@ -1,12 +1,16 @@
pkgbase = python-plotly
pkgdesc = An open-source, interactive graphing library
pkgver = 5.20.0
- pkgrel = 1
+ pkgrel = 2
url = https://github.com/plotly/plotly.py
- arch = x86_64
+ arch = any
license = MIT
checkdepends = python-requests
checkdepends = python-pytest
+ makedepends = git
+ makedepends = python-wheel
+ makedepends = python-build
+ makedepends = python-installer
makedepends = python-setuptools
makedepends = python-jupyter_core
makedepends = python-tornado
@@ -26,7 +30,8 @@ pkgbase = python-plotly
optdepends = python-inflect
optdepends = python-psutil
options = !strip
- source = python-plotly-5.20.0.tar.gz::https://github.com/plotly/plotly.py/archive/v5.20.0.tar.gz
- sha256sums = 5f871e5ec2ec5c554210f735414f1d12031175a401cf90bbca7556501a48b1df
+ options = !debug
+ source = python-plotly::git+https://github.com/plotly/plotly.py#tag=v5.20.0
+ sha256sums = SKIP
pkgname = python-plotly
diff --git a/PKGBUILD b/PKGBUILD
index fbc4962c0a8c..0edb7c64c8e2 100644
--- a/PKGBUILD
+++ b/PKGBUILD
@@ -3,60 +3,67 @@
pkgname=python-plotly
pkgver=5.20.0
-pkgrel=1
+pkgrel=2
pkgdesc="An open-source, interactive graphing library"
-arch=('x86_64')
+arch=('any')
url="https://github.com/plotly/plotly.py"
license=('MIT')
depends=(
-python
-python-tenacity
+ python
+ python-tenacity
)
# optdepends based on optional_requirements.txt
optdepends=(
-ipython
-jupyterlab
-python-ipywidgets
-python-numpy
-python-matplotlib
-python-pillow
-python-scipy
-python-ipykernel
-python-pandas
-python-colorcet
-python-inflect
-python-psutil
+ ipython
+ jupyterlab
+ python-ipywidgets
+ python-numpy
+ python-matplotlib
+ python-pillow
+ python-scipy
+ python-ipykernel
+ python-pandas
+ python-colorcet
+ python-inflect
+ python-psutil
)
makedepends=(
-python-setuptools
-python-jupyter_core
-python-tornado
-jupyterlab
+ git
+ python-wheel
+ python-build
+ python-installer
+ python-setuptools
+ python-jupyter_core
+ python-tornado
+ jupyterlab
)
checkdepends=(
-python-requests
-python-pytest
+ python-requests
+ python-pytest
)
source=(
-"${pkgname}-${pkgver}.tar.gz::https://github.com/plotly/plotly.py/archive/v${pkgver}.tar.gz"
+ "${pkgname}::git+https://github.com/plotly/plotly.py#tag=v$pkgver"
)
-options=(!strip) # strip isn't useful for python files and takes forever
-sha256sums=('5f871e5ec2ec5c554210f735414f1d12031175a401cf90bbca7556501a48b1df')
+options=(!strip !debug) # strip and debug aren't useful for python files and take forever
+sha256sums=('SKIP')
build() {
- cd plotly.py-${pkgver}/packages/python/plotly
- SKIP_NPM=1 python setup.py build
+ cd python-plotly/packages/python/plotly
+
+ # Skip the dependency check as the version bounds on jupyterlab are too tight
+ # and don't allow 4.x, which Arch currently ships.
+ SKIP_NPM=1 python -m build --wheel --no-isolation --skip-dependency-check
}
check() {
- cd plotly.py-${pkgver}/packages/python/plotly
+ cd python-plotly/packages/python/plotly
pytest plotly/tests/test_core
}
package() {
- cd plotly.py-${pkgver}/packages/python/plotly
- SKIP_NPM=1 python setup.py install --root="${pkgdir}" --optimize=1 --skip-build
- mv ${pkgdir}/usr/etc ${pkgdir}
+ cd python-plotly/packages/python/plotly
+ python -m installer --destdir="$pkgdir"/ dist/*.whl
+ mv "${pkgdir}/usr/etc" "${pkgdir}"
install -Dm644 LICENSE.txt "${pkgdir}/usr/share/licenses/${pkgname}/LICENSE"
}