Blame python-django-q.spec

7da8b6f
# "can't find tests module"
7da8b6f
%bcond_with tests
7da8b6f
7da8b6f
%global srcname django-q
7da8b6f
%global modname django_q
7da8b6f
7da8b6f
%global forgeurl https://github.com/koed00/django-q
7da8b6f
7da8b6f
Name:           python-%{srcname}
7da8b6f
Version:        1.3.9
7da8b6f
Release:        %autorelease
7da8b6f
Summary:        A multiprocessing distributed task queue for Django
7da8b6f
License:        MIT
7da8b6f
URL:            https://django-q.readthedocs.org/
7da8b6f
# pyproject.toml from GH doesn't seem to work
7da8b6f
Source0:        %{pypi_source %{srcname}}
7da8b6f
# Source0:        %%{forgeurl}/archive/v%%{version}/%%{srcname}-%%{version}.tar.gz
7da8b6f
7da8b6f
BuildArch:      noarch
7da8b6f
7da8b6f
BuildRequires:  python%{python3_pkgversion}-devel
7da8b6f
%if %{with tests}
7da8b6f
# Test dependencies:
7da8b6f
# BuildRequires:  python3dist(django-redis)
7da8b6f
%endif
7da8b6f
7da8b6f
%global _description %{expand:
7da8b6f
A multiprocessing distributed task queue for Django
7da8b6f
7da8b6f
Features:
7da8b6f
- Multiprocessing worker pool
7da8b6f
- Asynchronous tasks
7da8b6f
- Scheduled, cron and repeated tasks
7da8b6f
- Signed and compressed packages
7da8b6f
- Failure and success database or cache
7da8b6f
- Result hooks, groups and chains
7da8b6f
- Django Admin integration
7da8b6f
- PaaS compatible with multiple instances
7da8b6f
- Multi cluster monitor
7da8b6f
- Redis, Disque, IronMQ, SQS, MongoDB or ORM
7da8b6f
- Rollbar and Sentry support}
7da8b6f
7da8b6f
%description %{_description}
7da8b6f
7da8b6f
7da8b6f
%package -n python%{python3_pkgversion}-%{srcname}
7da8b6f
Summary:        %{summary}
7da8b6f
7da8b6f
%description -n python%{python3_pkgversion}-%{srcname} %{_description}
7da8b6f
7da8b6f
7da8b6f
%prep
7da8b6f
%autosetup -p1 -n %{srcname}-%{version}
7da8b6f
7da8b6f
7da8b6f
%generate_buildrequires
7da8b6f
# project's pyproject.toml caused our script to choke
7da8b6f
# seems fine when using PyPI
7da8b6f
%pyproject_buildrequires
7da8b6f
7da8b6f
7da8b6f
%build
7da8b6f
%pyproject_wheel
7da8b6f
7da8b6f
7da8b6f
%install
7da8b6f
# these installs UNKNOWN-0.0.0.dist-info
7da8b6f
# when using GH tarball
7da8b6f
%pyproject_install
7da8b6f
%pyproject_save_files %{modname}
7da8b6f
7da8b6f
7da8b6f
%if %{with tests}
7da8b6f
%check
7da8b6f
%python3 -m django test -v2 --settings=django_q.tests.settings
7da8b6f
%endif
7da8b6f
7da8b6f
7da8b6f
%files -n  python%{python3_pkgversion}-%{srcname} -f %{pyproject_files}
7da8b6f
%license LICENSE
7da8b6f
%doc CHANGELOG.md README.rst
7da8b6f
7da8b6f
7da8b6f
%changelog
7da8b6f
%autochangelog