15
0

Accepting request 975067 from home:mcalabkova:branches:devel:languages:python

- Update to 1.5
  * Drop support for jinaj2 <3. Add support for 3+.
  * Don't require typing_extensions on Python 3.8+.
- Drop merged stdlib-typing_extensions.patch

OBS-URL: https://build.opensuse.org/request/show/975067
OBS-URL: https://build.opensuse.org/package/show/devel:languages:python/python-aiohttp-jinja2?expand=0&rev=8
This commit is contained in:
2022-05-05 09:02:48 +00:00
committed by Git OBS Bridge
parent 09a62bc8f8
commit b8bfe045ce
5 changed files with 15 additions and 28 deletions

View File

@@ -1,3 +0,0 @@
version https://git-lfs.github.com/spec/v1
oid sha256:5d6939f0cd74a2c64f087af7b4b6c373b83c72ebbc7cc6a44154adcc2eec1f52
size 53503

View File

@@ -0,0 +1,3 @@
version https://git-lfs.github.com/spec/v1
oid sha256:6cba9e9b34c64c921f495d6d7fbb3fd3687a7095030c0534652b290e81cbc190
size 54427

View File

@@ -1,3 +1,11 @@
-------------------------------------------------------------------
Thu May 5 07:26:15 UTC 2022 - Markéta Machová <mmachova@suse.com>
- Update to 1.5
* Drop support for jinaj2 <3. Add support for 3+.
* Don't require typing_extensions on Python 3.8+.
- Drop merged stdlib-typing_extensions.patch
-------------------------------------------------------------------
Mon May 31 06:19:55 UTC 2021 - Matej Cepl <mcepl@suse.com>

View File

@@ -1,7 +1,7 @@
#
# spec file for package python-aiohttp-jinja2
#
# Copyright (c) 2021 SUSE LLC
# Copyright (c) 2022 SUSE LLC
#
# All modifications and additions to the file contributed by third parties
# remain the property of their copyright owners, unless otherwise agreed
@@ -19,28 +19,25 @@
%{?!python_module:%define python_module() python3-%{**}}
%define skip_python2 1
Name: python-aiohttp-jinja2
Version: 1.4.2
Version: 1.5
Release: 0
Summary: Jinja2 template renderer for aiohttp.web
License: Apache-2.0
Group: Development/Languages/Python
URL: https://github.com/aio-libs/aiohttp-jinja2
Source: https://github.com/aio-libs/aiohttp-jinja2/archive/v%{version}.tar.gz#/aiohttp-jinja2-%{version}.tar.gz
# PATCH-FIX-UPSTREAM stdlib-typing_extensions.patch gh#aio-libs/aiohttp-jinja2#451 mcepl@suse.com
# Make typing_extensions just optional dependency
Patch0: stdlib-typing_extensions.patch
BuildRequires: %{python_module setuptools}
BuildRequires: fdupes
BuildRequires: python-rpm-macros
BuildRequires: (python3-typing_extensions if python3-base <= 3.6)
Requires: python-Jinja2
Requires: python-Jinja2 >= 3.0
Requires: python-aiohttp
%if 0%{?python_version_nodots} <= 36
Requires: python3-typing_extensions
%endif
BuildArch: noarch
# SECTION test requirements
BuildRequires: %{python_module Jinja2}
BuildRequires: %{python_module Jinja2 >= 3.0}
BuildRequires: %{python_module aiohttp}
BuildRequires: %{python_module pytest-aiohttp}
# /SECTION

View File

@@ -1,18 +0,0 @@
---
aiohttp_jinja2/__init__.py | 5 ++++-
1 file changed, 4 insertions(+), 1 deletion(-)
--- a/aiohttp_jinja2/__init__.py
+++ b/aiohttp_jinja2/__init__.py
@@ -19,7 +19,10 @@ from typing import (
import jinja2
from aiohttp import web
from aiohttp.abc import AbstractView
-from typing_extensions import Protocol
+try:
+ from typing import Protocol
+except ImportError:
+ from typing_extensions import Protocol
from .helpers import GLOBAL_HELPERS
from .typedefs import Filters