Skip to content

Commit

Permalink
Merge pull request #89 from release-engineering/remove-python2-support
Browse files Browse the repository at this point in the history
remove python2 support
  • Loading branch information
mikebonnet authored Jan 17, 2020
2 parents 8920a8d + 0acba99 commit 0be22df
Show file tree
Hide file tree
Showing 4 changed files with 11 additions and 33 deletions.
3 changes: 1 addition & 2 deletions .travis.yml
Original file line number Diff line number Diff line change
@@ -1,8 +1,7 @@
dist: xenial
language: python
python:
- "2.7"
- "3.7"
- "3.8"
matrix:
include:
- python: "3.7"
Expand Down
31 changes: 8 additions & 23 deletions python-fedmsg-meta-umb.spec
Original file line number Diff line number Diff line change
Expand Up @@ -2,18 +2,18 @@
%global rpmname fedmsg-meta-umb

Name: python-%{rpmname}
Version: 0.0.2
Release: 3%{?dist}
Version: 0.0.3
Release: 1%{?dist}
Summary: fedmsg metadata provider plugins for the Unified Message Bus

License: LGPLv2+
URL: https://github.com/release-engineering/%{srcname}
Source0: %{srcname}-%{version}.tar.xz

BuildArch: noarch
BuildRequires: python2-devel python3-devel
BuildRequires: python2-nose python3-nose
BuildRequires: python2-fedmsg python3-fedmsg
BuildRequires: python3-devel
BuildRequires: python3-nose
BuildRequires: python3-fedmsg
BuildRequires: python3-mako
BuildRequires: python3-cloud-sptheme
BuildRequires: python3-sphinx
Expand All @@ -23,16 +23,6 @@ This package contains plugins to the fedmsg metadata provider for internal
Red Hat services attached to the Unified Message Bus.


%package -n python2-%{rpmname}
Summary: %{summary}
Requires: python2-fedmsg
%{?python_provide:%python_provide python2-%{rpmname}}

%description -n python2-%{rpmname}
This package contains plugins to the fedmsg metadata provider for internal
Red Hat services attached to the Unified Message Bus.


%package -n python3-%{rpmname}
Summary: %{summary}
Requires: python3-fedmsg
Expand All @@ -54,25 +44,17 @@ of the message topics and formats that are specific to the Unified Message Bus.
%autosetup -n %{srcname}-%{version}

%build
%py2_build
%py3_build
PYTHONPATH=. sphinx-build-3 doc/ htmldocs/

%install
%py2_install
%py3_install
%{__mkdir_p} %{buildroot}%{_datadir}/%{name}
%{__cp} -pr datagrepper-docs htmldocs %{buildroot}%{_datadir}/%{name}

%check
%{__python2} setup.py test
%{__python3} setup.py test

%files -n python2-%{rpmname}
%license LICENSE
%doc README.rst
%{python2_sitelib}/*

%files -n python3-%{rpmname}
%license LICENSE
%doc README.rst
Expand All @@ -82,6 +64,9 @@ PYTHONPATH=. sphinx-build-3 doc/ htmldocs/
%{_datadir}/%{name}

%changelog
* Fri Jan 17 2020 Mike Bonnet <mikeb@redhat.com> - 0.0.3-1
- remove python2 support, since fedmsg no longer supports it as of Fedora 31

* Tue Jul 3 2018 Mike Bonnet <mikeb@redhat.com> - 0.0.2-3
- install doesn't handle directories, use cp instead

Expand Down
2 changes: 1 addition & 1 deletion setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -65,7 +65,7 @@

setup(
name='fedmsg_meta_umb',
version='0.0.2',
version='0.0.3',
description="fedmsg metadata providers for services on Red Hat's Unified Message Bus",
long_description=long_description,
author='Mike Bonnet',
Expand Down
8 changes: 1 addition & 7 deletions tox.ini
Original file line number Diff line number Diff line change
@@ -1,29 +1,23 @@
[tox]
envlist = flake8,py{27,37},docs
envlist = flake8,py{37,38},docs
downloadcache = {toxworkdir}/_download/

[testenv]
basepython =
py27: python2.7
py37: python3.7
deps =
fedmsg
nose
coverage
sitepackages = False
commands =
nosetests {posargs}

[testenv:flake8]
basepython = python3.7
deps=
flake8
commands=
flake8 --version
flake8

[testenv:docs]
basepython = python3.7
deps =
cloud_sptheme
nose
Expand Down

0 comments on commit 0be22df

Please sign in to comment.