# POWER Maintainer: Alexander Baldeck <alex.bldck@gmail.com>
# Maintainer: zhullyb <zhullyb@outlook.com>

_pyname=taskflow
pkgname=python-$_pyname
pkgver=5.2.0
pkgrel=1
pkgdesc="Taskflow structured state management library."
arch=(any)
url="https://docs.openstack.org/taskflow/latest/"
license=(Apache)
depends=(
	python
	python-pbr
	python-six
	python-futurist
	python-fasteners
	python-networkx
	python-stevedore
	python-jsonschema
	python-automaton
	python-oslo-utils
	python-oslo-serialization
	python-tenacity
	python-cachetools
	python-pydot
)
makedepends=(
	python
)
checkdepends=(
	python-kazoo
	python-zake
	python-redis
	python-kombu
	python-eventlet
	python-sqlalchemy
	python-alembic
	python-sqlalchemy-utils
	python-pymysql
	python-psycopg2
	python-pydotplus
	python-hacking
	python-oslotest
	python-mock
	python-testtools
	python-testscenarios
	python-stestr
	python-pre-commit
)
optdepends=(
	python-kazoo
	python-zake
	python-redis
	python-kombu
	python-eventlet
	python-sqlalchemy
	python-alembic
	python-sqlalchemy-utils
	python-pymysql
	python-psycopg2
)
source=(https://pypi.io/packages/source/${_pyname::1}/$_pyname/$_pyname-$pkgver.tar.gz)
md5sums=('f6dd5039cb67d2de3c611f7949b5bb9a')
sha256sums=('3fee1454d37ae79a8170e1b048790b99380edd1c857d8fffa5f35ecb45707941')
sha512sums=('356186b3e105c353fa29c4bfcb8e501fb17922f4f8af893f9b013569dccf16272ddc8f91cbc758ba9615780f529e2a93c3cdaf0414e8df39486eb4a78ccf969e')

export PBR_VERSION=$pkgver

build(){
	pushd $_pyname-$pkgver
	python setup.py build
}

## Test broken
#check(){
#	pushd $_pyname-$pkgver
#	stestr run
#}

package(){
	cd $_pyname-$pkgver
	python setup.py install --root "$pkgdir" --optimize=1
	install -Dm644 LICENSE "$pkgdir"/usr/share/licenses/$pkgname/LICENSE
}
