Update to 2.6.0 (Jan Beran)
Fix of missing Python 3 version executables (Jan Beran) Resolves: rhbz#1436800 Resolves: rhbz#1419376
This commit is contained in:
parent
d5a241fb95
commit
1abd40cb27
1
.gitignore
vendored
1
.gitignore
vendored
@ -4,3 +4,4 @@
|
||||
/jsonschema-2.3.0.tar.gz
|
||||
/jsonschema-2.4.0.tar.gz
|
||||
/jsonschema-2.5.1.tar.gz
|
||||
/jsonschema-2.6.0.tar.gz
|
||||
|
||||
@ -1,26 +1,30 @@
|
||||
diff -ru jsonschema-2.5.1.orig/jsonschema/compat.py jsonschema-2.5.1/jsonschema/compat.py
|
||||
--- jsonschema-2.5.1.orig/jsonschema/compat.py 2015-04-13 17:23:46.000000000 +0200
|
||||
+++ jsonschema-2.5.1/jsonschema/compat.py 2016-02-27 16:33:40.938583562 +0100
|
||||
@@ -9,6 +9,7 @@
|
||||
diff -ru jsonschema-2.6.0.orig/jsonschema/compat.py jsonschema-2.6.0/jsonschema/compat.py
|
||||
--- jsonschema-2.6.0.orig/jsonschema/compat.py 2015-11-30 13:58:04.000000000 +0100
|
||||
+++ jsonschema-2.6.0/jsonschema/compat.py 2017-07-21 12:57:25.768508757 +0200
|
||||
@@ -8,6 +8,7 @@
|
||||
from collections.abc import MutableMapping, Sequence # noqa
|
||||
|
||||
PY3 = sys.version_info[0] >= 3
|
||||
PY26 = sys.version_info[:2] == (2, 6)
|
||||
+PY27 = sys.version_info[:2] == (2, 7)
|
||||
|
||||
if PY3:
|
||||
zip = zip
|
||||
@@ -33,7 +34,7 @@
|
||||
@@ -32,8 +33,10 @@
|
||||
int_types = int, long
|
||||
iteritems = operator.methodcaller("iteritems")
|
||||
|
||||
- if PY26:
|
||||
+ if PY26 or PY27:
|
||||
from repoze.lru import lru_cache
|
||||
else:
|
||||
from functools32 import lru_cache
|
||||
diff -ru jsonschema-2.5.1.orig/setup.py jsonschema-2.5.1/setup.py
|
||||
--- jsonschema-2.5.1.orig/setup.py 2015-06-08 18:04:36.000000000 +0200
|
||||
+++ jsonschema-2.5.1/setup.py 2016-02-27 16:34:40.462446660 +0100
|
||||
- from functools32 import lru_cache
|
||||
-
|
||||
+ if PY27:
|
||||
+ from repoze.lru import lru_cache
|
||||
+ else:
|
||||
+ from functools32 import lru_cache
|
||||
|
||||
# On python < 3.3 fragments are not handled properly with unknown schemes
|
||||
def urlsplit(url):
|
||||
diff -ru jsonschema-2.6.0.orig/setup.py jsonschema-2.6.0/setup.py
|
||||
--- jsonschema-2.6.0.orig/setup.py 2016-08-28 04:29:36.000000000 +0200
|
||||
+++ jsonschema-2.6.0/setup.py 2017-07-21 13:28:06.503903938 +0200
|
||||
@@ -1,6 +1,7 @@
|
||||
import os
|
||||
|
||||
@ -29,10 +33,10 @@ diff -ru jsonschema-2.5.1.orig/setup.py jsonschema-2.5.1/setup.py
|
||||
|
||||
|
||||
with open(os.path.join(os.path.dirname(__file__), "README.rst")) as readme:
|
||||
@@ -24,14 +25,14 @@
|
||||
@@ -22,14 +23,14 @@
|
||||
|
||||
extras_require = {
|
||||
"format" : ["rfc3987", "strict-rfc3339", "webcolors"],
|
||||
":python_version=='2.6'": ["argparse", "repoze.lru"],
|
||||
- ":python_version=='2.7'": ["functools32"],
|
||||
+ ":python_version=='2.7'": ["repoze.lru"],
|
||||
}
|
||||
@ -42,11 +46,11 @@ diff -ru jsonschema-2.5.1.orig/setup.py jsonschema-2.5.1/setup.py
|
||||
+ version=_version.__version__,
|
||||
packages=["jsonschema", "jsonschema.tests"],
|
||||
package_data={"jsonschema": ["schemas/*.json"]},
|
||||
- setup_requires=["vcversioner"],
|
||||
- setup_requires=["vcversioner>=2.16.0.0"],
|
||||
extras_require=extras_require,
|
||||
author="Julian Berman",
|
||||
author_email="Julian@GrayVines.com",
|
||||
@@ -41,5 +42,4 @@
|
||||
@@ -39,5 +40,4 @@
|
||||
long_description=long_description,
|
||||
url="http://github.com/Julian/jsonschema",
|
||||
entry_points={"console_scripts": ["jsonschema = jsonschema.cli:main"]},
|
||||
@ -4,13 +4,13 @@
|
||||
%global with_python3 1
|
||||
|
||||
Name: python-%{pypi_name}
|
||||
Version: 2.5.1
|
||||
Release: 5%{?dist}
|
||||
Version: 2.6.0
|
||||
Release: 1%{?dist}
|
||||
Summary: An implementation of JSON Schema validation for Python
|
||||
|
||||
License: MIT
|
||||
URL: http://pypi.python.org/pypi/jsonschema
|
||||
Source0: http://pypi.python.org/packages/source/j/jsonschema/%{pypi_name}-%{version}.tar.gz
|
||||
Source0: https://files.pythonhosted.org/packages/source/j/jsonschema/%{pypi_name}-%{version}.tar.gz
|
||||
BuildArch: noarch
|
||||
|
||||
%if %{?rhel}%{!?rhel:0} == 6
|
||||
@ -32,7 +32,7 @@ BuildRequires: python%{python3_pkgversion}-mock
|
||||
%endif
|
||||
|
||||
# avoid functools32, vcversioner
|
||||
Patch0: avoid-unpackaged.patch
|
||||
Patch0: avoid-unpackaged-for-jsonschema-2.6.0.patch
|
||||
|
||||
%description
|
||||
jsonschema is JSON Schema validator currently based on
|
||||
@ -72,6 +72,7 @@ http://tools.ietf.org/html/draft-zyp-json-schema-03
|
||||
%install
|
||||
%if 0%{?with_python3}
|
||||
%py3_install
|
||||
mv %{buildroot}%{_bindir}/jsonschema %{buildroot}%{_bindir}/jsonschema-3
|
||||
%endif
|
||||
%py2_install
|
||||
|
||||
@ -92,12 +93,17 @@ http://tools.ietf.org/html/draft-zyp-json-schema-03
|
||||
%files -n python%{python3_pkgversion}-%{pypi_name}
|
||||
%license COPYING
|
||||
%doc README.rst
|
||||
%{_bindir}/jsonschema-3
|
||||
%{python3_sitelib}/%{pypi_name}/
|
||||
%{python3_sitelib}/%{pypi_name}-%{version}-py?.?.egg-info
|
||||
%endif
|
||||
|
||||
|
||||
%changelog
|
||||
* Fri Jul 21 2017 Jan Beran <jberan@redhat.com> 2.6.0-1
|
||||
- Update to 2.6.0
|
||||
- Fix of missing Python 3 version executables
|
||||
|
||||
* Sat Feb 11 2017 Fedora Release Engineering <releng@fedoraproject.org> - 2.5.1-5
|
||||
- Rebuilt for https://fedoraproject.org/wiki/Fedora_26_Mass_Rebuild
|
||||
|
||||
|
||||
Loading…
Reference in New Issue
Block a user