dc8f213
%global modname alembic
dc8f213
dc8f213
Name:             python-alembic
ac61c9a
Version:          1.7.5
f655772
Release:          1%{?dist}
dc8f213
Summary:          Database migration tool for SQLAlchemy
dc8f213
dc8f213
License:          MIT
9e1dd60
URL:              https://pypi.io/project/alembic
b2935d8
Source0:          %pypi_source alembic
896b32f
5ec9ba7
# Alembic fails with Python 3.10.0b2 due to DeprecationWarnings treated as an error.
5ec9ba7
# Downstream report: https://bugzilla.redhat.com/show_bug.cgi?id=1958159
5ec9ba7
Patch1:           0001-filter-out-DeprecationWarnings.patch
5ec9ba7
dc8f213
BuildArch:        noarch
dc8f213
dc8f213
BuildRequires:    help2man
ff2ff58
dc8f213
BuildRequires:    python3-devel
4f1c261
BuildRequires:    python3-sqlalchemy >= 1.1
dc8f213
BuildRequires:    python3-mako
dc8f213
BuildRequires:    python3-nose
e160057
BuildRequires:    python3-setuptools
c146b27
BuildRequires:    python3-mock
e2b1806
BuildRequires:    python3-dateutil
24a7c65
BuildRequires:    python3-editor
24a7c65
BuildRequires:    python3-pytest
5e72c8c
%if 0%{?rhel} == 8
5e72c8c
BuildRequires:    python3-importlib-resources
5e72c8c
%endif
dc8f213
dc8f213
cd6b849
%global _description\
cd6b849
Alembic is a new database migrations tool, written by the author of\
cd6b849
SQLAlchemy.  A migrations tool offers the following functionality:\
cd6b849
\
cd6b849
* Can emit ALTER statements to a database in order to change the structure\
cd6b849
  of tables and other constructs.\
cd6b849
* Provides a system whereby "migration scripts" may be constructed; each script\
cd6b849
  indicates a particular series of steps that can "upgrade" a target database\
cd6b849
  to a new version, and optionally a series of steps that can "downgrade"\
cd6b849
  similarly, doing the same steps in reverse.\
cd6b849
* Allows the scripts to execute in some sequential manner.\
cd6b849
\
cd6b849
Documentation and status of Alembic is at http://readthedocs.org/docs/alembic/
dc8f213
cd6b849
%description %_description
dc8f213
cd6b849
dc8f213
%package -n python3-alembic
cd6b849
Summary:          %summary
dc8f213
5e72c8c
%if 0%{?rhel} == 8
5e72c8c
Requires:         python3-importlib-resources
5e72c8c
%endif
cd6b849
%{?python_provide:%python_provide python3-alembic}
dc8f213
a25c536
cd6b849
%description -n python3-alembic %_description
dc8f213
dc8f213
%prep
896b32f
%autosetup -p1 -n %{modname}-%{version}
dc8f213
dc8f213
dc8f213
%build
275596c
%py3_build
dc8f213
dc8f213
%{__mkdir_p} bin
24a7c65
echo 'python3 -c "import alembic.config; alembic.config.main()" $*' > bin/alembic
24a7c65
chmod 0755 bin/alembic
24a7c65
help2man --version-string %{version} --no-info -s 1 bin/alembic > alembic.1
dc8f213
dc8f213
dc8f213
%install
24a7c65
dc8f213
install -d -m 0755 %{buildroot}%{_mandir}/man1
24a7c65
275596c
%py3_install
392dc63
mv %{buildroot}/%{_bindir}/%{modname} %{buildroot}/%{_bindir}/%{modname}-3
941b664
ln -s %{modname}-3 %{buildroot}/%{_bindir}/%{modname}-%{python3_version}
392dc63
install -m 0644 alembic.1 %{buildroot}%{_mandir}/man1/alembic-3.1
941b664
ln -s alembic-3.1 %{buildroot}%{_mandir}/man1/alembic-%{python3_version}.1
392dc63
f7f8044
ln -s %{modname}-%{python3_version} %{buildroot}/%{_bindir}/%{modname}
f7f8044
ln -s alembic-%{python3_version}.1 %{buildroot}%{_mandir}/man1/alembic.1
941b664
dc8f213
24a7c65
%check
4f1c261
py.test-3
dc8f213
dc8f213
dc8f213
%files -n python3-%{modname}
dc8f213
%doc LICENSE README.rst CHANGES docs
dc8f213
%{python3_sitelib}/%{modname}/
dc8f213
%{python3_sitelib}/%{modname}-%{version}-*
941b664
%{_bindir}/%{modname}
941b664
%{_mandir}/man1/alembic.1*
392dc63
%{_bindir}/%{modname}-3
392dc63
%{_bindir}/%{modname}-%{python3_version}
392dc63
%{_mandir}/man1/alembic-3.1*
392dc63
%{_mandir}/man1/alembic-%{python3_version}.1*
dc8f213
dc8f213
dc8f213
%changelog
ac61c9a
* Sun Nov 28 2021 Kevin Fenzi <kevin@scrye.com> - 1.7.5-1
ac61c9a
- Update to 1.7.5. Fixes rhbz#2022454
ac61c9a
532f0b9
* Sat Nov 06 2021 Kevin Fenzi <kevin@scrye.com> - 1.7.4-1
532f0b9
- Update to 1.7.4. Fixes rhbz#2011425
532f0b9
f655772
* Sat Sep 25 2021 Kevin Fenzi <kevin@scrye.com> - 1.7.3-1
f655772
- Update to 1.7.3. Fixes rhbz#2005403
f655772
3e6c78c
* Fri Sep 17 2021 Neal Gompa <ngompa@fedoraproject.org> - 1.7.1-3
3e6c78c
- Drop redundant manually specified dependencies
3e6c78c
09a5a79
* Thu Sep 16 2021 Joel Capitao <jcapitao@redhat.com> - 1.7.1-2
09a5a79
- Add the dist tag again
09a5a79
5e72c8c
* Mon Sep 13 2021 Joel Capitao <jcapitao@redhat.com> - 1.7.1-1
5e72c8c
- Update to 1.7.1. Fixes rhbz#1999176
5e72c8c
c1a737a
* Fri Jul 23 2021 Fedora Release Engineering <releng@fedoraproject.org> - 1.6.5-2
c1a737a
- Rebuilt for https://fedoraproject.org/wiki/Fedora_35_Mass_Rebuild
c1a737a
7c26137
* Sat Jun 12 2021 Kevin Fenzi <kevin@scrye.com> - 1.6.5-1
7c26137
- Update to 1.6.5. Fixes rhbz#1964163
7c26137
c57c776
* Fri Jun 04 2021 Python Maint <python-maint@redhat.com> - 1.6.3-2
c57c776
- Rebuilt for Python 3.10
c57c776
eb3488f
* Sat May 22 2021 Kevin Fenzi <kevin@scrye.com> - 1.6.3-1
eb3488f
- Update to 1.6.3. Fixes rhbz#1957878
eb3488f
c9886df
* Tue May 04 2021 Kevin Fenzi <kevin@scrye.com> - 1.6.0-1
c9886df
- Update to 1.6.0. Fixes rhbz#1956482
c9886df
5a2e37b
* Sat Mar 27 2021 Kevin Fenzi <kevin@scrye.com> - 1.5.8-1
5a2e37b
- Update to 1.5.8. Fixes rhbz#1935790
5a2e37b
ccde585
* Mon Feb 22 2021 Kevin Fenzi <kevin@scrye.com> - 1.5.5-1
ccde585
- Update to 1.5.5. Fixes rhbz#1931142
ccde585
42657a9
* Fri Feb 12 2021 Kevin Fenzi <kevin@scrye.com> - 1.5.3-1
42657a9
- Update to 1.5.3. Fixes rhbz#1922496
42657a9
8c5e2bb
* Thu Jan 28 2021 Kevin Fenzi <kevin@scrye.com> - 1.5.0-1
8c5e2bb
- Update to 1.5.0. Fixes rhbz#1917596
8c5e2bb
c9be03f
* Wed Jan 27 2021 Fedora Release Engineering <releng@fedoraproject.org> - 1.4.3-2
c9be03f
- Rebuilt for https://fedoraproject.org/wiki/Fedora_34_Mass_Rebuild
c9be03f
902eed9
* Thu Nov 19 2020 Joel Capitao <jcapitao@redhat.com> - 1.4.3-1
902eed9
- Update to 1.4.3 (rhbz#1878203)
902eed9
f7f8044
* Thu Aug 20 2020 Merlin Mathesius <mmathesi@redhat.com> - 1.4.2-5
f7f8044
- Correct macro usage to fix Rawhide and ELN FTBFS errors
f7f8044
f5c343b
* Sat Aug 01 2020 Fedora Release Engineering <releng@fedoraproject.org> - 1.4.2-4
f5c343b
- Second attempt - Rebuilt for
f5c343b
  https://fedoraproject.org/wiki/Fedora_33_Mass_Rebuild
f5c343b
9b06894
* Tue Jul 28 2020 Fedora Release Engineering <releng@fedoraproject.org> - 1.4.2-3
9b06894
- Rebuilt for https://fedoraproject.org/wiki/Fedora_33_Mass_Rebuild
9b06894
128cfad
* Sun May 24 2020 Miro Hrončok <mhroncok@redhat.com> - 1.4.2-2
128cfad
- Rebuilt for Python 3.9
128cfad
3172973
* Sun Mar 22 2020 Carl George <carl@george.computer> - 1.4.2-1
3172973
- Latest upstream rhbz#1808866
3172973
e3fa651
* Wed Feb 19 2020 Randy Barlow <bowlofeggs@fedoraproject.org> - 1.4.0-1
e3fa651
- Update to 1.4.0 (#1784129).
e3fa651
- https://alembic.sqlalchemy.org/en/latest/changelog.html#change-1.4.0
e3fa651
088eff0
* Thu Jan 30 2020 Fedora Release Engineering <releng@fedoraproject.org> - 1.3.1-2
088eff0
- Rebuilt for https://fedoraproject.org/wiki/Fedora_32_Mass_Rebuild
088eff0
e4a52eb
* Mon Nov 18 2019 Randy Barlow <bowlofeggs@fedoraproject.org> - 1.3.1-1
e4a52eb
- Update to 1.3.1 (#1767518).
e4a52eb
- https://alembic.sqlalchemy.org/en/latest/changelog.html#change-1.3.1
e4a52eb
7aed158
* Fri Sep 27 2019 Randy Barlow <bowlofeggs@fedoraproject.org> - 1.2.1-1
7aed158
- Update to 1.2.1 (#1754016).
7aed158
- https://alembic.sqlalchemy.org/en/latest/changelog.html#change-1.2.1
7aed158
783d24d
* Tue Sep 17 2019 Randy Barlow <bowlofeggs@fedoraproject.org> - 1.1.0-2
783d24d
- Drop python2-alembic (#1751088).
783d24d
4f1c261
* Tue Sep 03 2019 Randy Barlow <bowlofeggs@fedoraproject.org> - 1.1.0-1
4f1c261
- Upgrade to 1.1.0 (#1747053).
4f1c261
- https://alembic.sqlalchemy.org/en/latest/changelog.html#change-1.1.0
4f1c261
e5e1158
* Sun Aug 18 2019 Miro Hrončok <mhroncok@redhat.com> - 1.0.11-3
e5e1158
- Rebuilt for Python 3.8
e5e1158
941b664
* Mon Jul 22 2019 Petr Viktorin <pviktori@redhat.com> - 1.0.11-2
941b664
- Make /usr/bin/alembic point to alembic-3 on Fedora 31+
941b664
  See https://fedoraproject.org/wiki/Changes/Python_means_Python3
941b664
- Avoid absolute symlinks
c7fdae3
- Conditionalize the Python 2/Python 3 parts with bcond
941b664
4c64425
* Sun Jun 30 2019 Kevin Fenzi <kevin@scrye.com> - 1.0.11-1
4c64425
- Update to 1.0.11. Fixes bug #1723981
4c64425
ff2ff58
* Wed Jun 19 2019 Troy Dawson <tdawson@redhat.com> - 1.0.10-1.1
ff2ff58
- Make python2 optional
ff2ff58
- Do not build python2 on RHEL8
ff2ff58
189fcd0
* Wed Jun 05 2019 Randy Barlow <bowlofeggs@fedoraproject.org> - 1.0.10-1
189fcd0
- Update to 1.0.10 (#1700050).
189fcd0
- https://alembic.sqlalchemy.org/en/latest/changelog.html#change-1.0.10
189fcd0
1a8ab75
* Thu Mar 28 2019 Randy Barlow <bowlofeggs@fedoraproject.org> - 1.0.8-1
1a8ab75
- Update to 1.0.8 (#1685262).
1a8ab75
- https://alembic.sqlalchemy.org/en/latest/changelog.html#change-1.0.8
1a8ab75
168a35b
* Tue Feb 05 2019 Alfredo Moralejo <amoralej@redhat.com> - 1.0.7-1
168a35b
- Update to 1.0.7
168a35b
dd95074
* Sat Feb 02 2019 Fedora Release Engineering <releng@fedoraproject.org> - 1.0.0-2
dd95074
- Rebuilt for https://fedoraproject.org/wiki/Fedora_30_Mass_Rebuild
dd95074
b2935d8
* Wed Jul 25 2018 Pierre-Yves Chibon <pingou@pingoured.fr> - 1.0.0-1
b2935d8
- Update to 1.0.0
b2935d8
74eee9e
* Fri Jul 13 2018 Fedora Release Engineering <releng@fedoraproject.org> - 0.9.7-7
74eee9e
- Rebuilt for https://fedoraproject.org/wiki/Fedora_29_Mass_Rebuild
74eee9e
b5d95b8
* Tue Jun 19 2018 Miro Hrončok <mhroncok@redhat.com> - 0.9.7-6
b5d95b8
- Rebuilt for Python 3.7
b5d95b8
efeb836
* Sun Jun 17 2018 Miro Hrončok <mhroncok@redhat.com> - 0.9.7-5
efeb836
- Rebuilt for Python 3.7
efeb836
54db439
* Wed Feb 21 2018 Iryna Shcherbina <ishcherb@redhat.com> - 0.9.7-4
54db439
- Update Python 2 dependency declarations to new packaging standards
54db439
  (See https://fedoraproject.org/wiki/FinalizingFedoraSwitchtoPython3)
54db439
392dc63
* Thu Feb 08 2018 Randy Barlow <bowlofeggs@fedoraproject.org> - 0.9.7-3
392dc63
- The python3-alembic package now provides only alembic-3 and alembic-3.y.
392dc63
- The python2-alembic package now provides alembic, alembic-2, and alembic-2.y.
392dc63
24a7c65
* Sat Jan 27 2018 Ralph Bean <rbean@redhat.com> - 0.9.7-2
24a7c65
- The python3-alembic package now provides the alembic executable.
24a7c65
e2b1806
* Thu Jan 18 2018 Ralph Bean <rbean@redhat.com> - 0.9.7-1
e2b1806
- new version
e2b1806
- New dependency on python-dateutil.