## START: Set by rpmautospec
## (rpmautospec version 0.6.0)
## RPMAUTOSPEC: autorelease, autochangelog
%define autorelease(e:s:pb:n) %{?-p:0.}%{lua:
    release_number = 1;
    base_release_number = tonumber(rpm.expand("%{?-b*}%{!?-b:1}"));
    print(release_number + base_release_number - 1);
}%{?-e:.%{-e*}}%{?-s:.%{-s*}}%{!?-n:%{?dist}}
## END: Set by rpmautospec

# Work around a circular dependency on snakemake and on
# python-snakemake-executor-plugin-cluster-generic.
%bcond bootstrap 0

Name:           python-snakemake-interface-executor-plugins
Version:        9.2.0
Release:        %autorelease
Summary:        Stable interface for interactions between Snakemake and its executor plugins

# SPDX
License:        MIT
URL:            https://github.com/snakemake/snakemake-interface-executor-plugins
# We use the GitHub archive instead of the PyPI sdist to get CHANGELOG.md and
# the tests.
Source:         %{url}/archive/v%{version}/snakemake-interface-executor-plugins-%{version}.tar.gz

BuildArch:      noarch

BuildRequires:  python3-devel
%if %{without bootstrap}
# See: [tool.poetry.dev-dependencies] in pyproject.toml
BuildRequires:  %{py3_dist pytest}
BuildRequires:  snakemake >= 8
BuildRequires:  %{py3_dist snakemake-executor-plugin-cluster-generic}
%endif

%global common_description %{expand:
This package provides a stable interface for interactions between Snakemake and
its executor plugins.}

%description %{common_description}


%package -n python3-snakemake-interface-executor-plugins
Summary:        %{summary}

%description -n python3-snakemake-interface-executor-plugins %{common_description}


%prep
%autosetup -n snakemake-interface-executor-plugins-%{version}


%generate_buildrequires
%pyproject_buildrequires


%build
%pyproject_wheel


%install
%pyproject_install
%pyproject_save_files snakemake_interface_executor_plugins


%check
# Just in case the tests are not very thorough:
%pyproject_check_import

%if %{without bootstrap}
%pytest -v tests/tests.py
%endif


%files -n python3-snakemake-interface-executor-plugins -f %{pyproject_files}
%license LICENSE
%doc CHANGELOG.md
%doc README.md


%changelog
## START: Generated by rpmautospec
* Fri Jul 05 2024 Packit <hello@packit.dev> - 9.2.0-1
- Update to 9.2.0 upstream release
- Resolves: rhbz#2295974

* Sun Jun 09 2024 Python Maint <python-maint@redhat.com> - 9.1.1-3
- Rebuilt for Python 3.13

* Fri Jun 07 2024 Python Maint <python-maint@redhat.com> - 9.1.1-2
- Bootstrap for Python 3.13

* Sat Apr 13 2024 Packit <hello@packit.dev> - 9.1.1-1
- Update to 9.1.1 upstream release
- Resolves: rhbz#2274844

* Wed Mar 27 2024 Packit <hello@packit.dev> - 9.1.0-1
- [packit] 9.1.0 upstream release
- Resolves: rhbz#2271077

* Mon Mar 11 2024 Benjamin A. Beasley <code@musicinmybrain.net> - 9.0.0-1
- Update to 9.0.0

* Fri Jan 26 2024 Fedora Release Engineering <releng@fedoraproject.org> - 8.2.0-2
- Rebuilt for https://fedoraproject.org/wiki/Fedora_40_Mass_Rebuild

* Fri Jan 19 2024 Benjamin A. Beasley <code@musicinmybrain.net> - 8.2.0-1
- Update to 8.2.0

* Fri Jan 19 2024 Benjamin A. Beasley <code@musicinmybrain.net> - 8.1.3-3
- Non-bootstrap build

* Thu Jan 11 2024 Benjamin A. Beasley <code@musicinmybrain.net> - 8.1.3-1
- Initial package (close RHBZ#2257524)
## END: Generated by rpmautospec