Blame python-sklearn-nature-inspired-algorithms.spec

a347370
%global pypi_name sklearn-nature-inspired-algorithms
a347370
%global pretty_name sklearn_nature_inspired_algorithms
a347370
%global github_name Sklearn-Nature-Inspired-Algorithms
a347370
a347370
# Pulls in fonts, currently disabled
a347370
# We refer to upstream's documentation.
a347370
%bcond_with generated_docs
4c5c5f8
%bcond_with tests
a347370
a347370
%global _description %{expand:
a347370
Nature inspired algorithms for hyper-parameter tuning of scikit-learn models.
a347370
This package uses algorithms implementation from NiaPy.
a347370
a347370
Documentation is available at:
a347370
https://sklearn-nature-inspired-algorithms.readthedocs.io/en/stable/ }
a347370
a347370
Name:           python-%{pypi_name}
53fa870
Version:        0.5.1
53fa870
Release:        1%{?dist}
a347370
Summary:        Nature Inspired Algorithms for scikit-learn
a347370
a347370
License:        MIT
a347370
URL:            https://github.com/timzatko/%{github_name}
a347370
Source0:        %{url}/archive/v%{version}/%{github_name}-%{version}.tar.gz
a347370
# Update pyproject.toml to match Fedora package versions
a347370
Patch0:         0001-Allow-using-fedora-dep-versions.patch
a347370
a347370
# For the patch
a347370
BuildRequires:  git-core
a347370
a347370
BuildArch:      noarch
a347370
a347370
%{?python_enable_dependency_generator}
a347370
a347370
%description %_description
a347370
a347370
%package -n python3-%{pypi_name}
a347370
Summary:        %{summary}
a347370
a347370
BuildRequires:  pyproject-rpm-macros
a347370
BuildRequires: %{py3_dist lockfile}
a347370
BuildRequires: %{py3_dist packaging}
a347370
BuildRequires: %{py3_dist pep517}
a347370
BuildRequires: %{py3_dist poetry}
a347370
BuildRequires: %{py3_dist wheel}
a347370
a347370
%{?python_provide:%python_provide python3-%{pypi_name}}
a347370
a347370
%description -n python3-%{pypi_name} %_description
a347370
a347370
%if %{with generated_docs}
a347370
%package doc
a347370
Summary:        %{summary}
a347370
BuildRequires:  %{py3_dist sphinx}
a347370
BuildRequires:  %{py3_dist sphinx-rtd-theme}
a347370
a347370
a347370
%description doc
a347370
Generated documentation for %{name}.
a347370
%endif
a347370
a347370
%prep
a347370
%autosetup -n %{github_name}-%{version} -S git
a347370
rm -rf %{pretty_name}.egg-info
a347370
rm -fv poetry.lock
a347370
a347370
%generate_buildrequires
a347370
%pyproject_buildrequires -r
a347370
a347370
%build
a347370
%pyproject_wheel
a347370
a347370
#not included in Pypi package
a347370
%if %{with generated_docs}
a347370
PYTHONPATH=. make -C docs SPHINXBUILD=sphinx-build-3 html
a347370
rm -rf docs/_build/html/{.doctrees,.buildinfo} -vf
a347370
%endif
a347370
a347370
%install
a347370
%pyproject_install
a347370
%pyproject_save_files sklearn_nature_inspired_algorithms
a347370
a347370
%check
a347370
%if %{with tests}
a347370
PYTHONPATH=%{buildroot}/%{python3_sitelib} %{__python3} -m unittest tests
a347370
%endif
a347370
a347370
%files -n python3-%{pypi_name} -f %{pyproject_files}
a347370
%license LICENSE
a347370
%doc README.md
a347370
%doc examples
a347370
a347370
%if %{with generated_docs}
a347370
%files doc
a347370
%license LICENSE
a347370
%doc docs/_build/html
a347370
%endif
a347370
a347370
%changelog
53fa870
* Tue Apr 6 2021 Iztok Fister Jr. <iztokf AT fedoraproject DOT org> - 0.5.1-1
53fa870
- New version
53fa870
9198641
* Wed Jan 27 2021 Fedora Release Engineering <releng@fedoraproject.org> - 0.4.6-4
9198641
- Rebuilt for https://fedoraproject.org/wiki/Fedora_34_Mass_Rebuild
9198641
4c5c5f8
* Thu Jan 21 2021 Iztok Fister Jr. <iztokf AT fedoraproject DOT org> - 0.4.6-3
4c5c5f8
- Do not test - scikit problems (Will be re-enabled)
4c5c5f8
a347370
* Fri Oct 09 2020 Ankur Sinha <ankursinha AT fedoraproject DOT org> - 0.4.6-2
a347370
- Do not include generated docs: bundle lots of fonts
a347370
- Correct doc generation command
a347370
a347370
* Fri Aug 14 2020 Ankur Sinha <ankursinha AT fedoraproject DOT org> - 0.4.5-1
a347370
- Update to use poetry
a347370
- correct URLS
a347370
- add conditionals for test and docs
a347370
a347370
* Mon Jul 27 2020 Iztok Fister Jr. <iztokf AT fedoraproject DOT org> - 0.4.5-1
a347370
- Initial package