From 8bb82246ae8b49593012f264bb73c7387b149e6aec0569c461557830ba2f522b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Mark=C3=A9ta=20Machov=C3=A1?= Date: Thu, 5 Aug 2021 15:31:45 +0000 Subject: [PATCH] Accepting request 910344 from home:mcalabkova:branches:devel:languages:python - Add upstream patch kwsyntax.patch OBS-URL: https://build.opensuse.org/request/show/910344 OBS-URL: https://build.opensuse.org/package/show/devel:languages:python/python-decorator?expand=0&rev=49 --- kwsyntax.patch | 36 ++++++++++++++++++++++++++++++++++++ python-decorator.changes | 5 +++++ python-decorator.spec | 3 +++ 3 files changed, 44 insertions(+) create mode 100644 kwsyntax.patch diff --git a/kwsyntax.patch b/kwsyntax.patch new file mode 100644 index 0000000..ca9ff49 --- /dev/null +++ b/kwsyntax.patch @@ -0,0 +1,36 @@ +From 817d070db3c9cc5900d118837c533c039982b050 Mon Sep 17 00:00:00 2001 +From: Michele Simionato +Date: Fri, 28 May 2021 08:30:09 +0200 +Subject: [PATCH] Fixed decorator.decorator not passing kwsyntax + +--- + CHANGES.md | 2 ++ + src/decorator.py | 2 +- + 2 files changed, 3 insertions(+), 1 deletion(-) + +diff --git a/CHANGES.md b/CHANGES.md +index 596559b..876df34 100644 +--- a/CHANGES.md ++++ b/CHANGES.md +@@ -3,6 +3,8 @@ HISTORY + + ## unreleased + ++decorator.decorator was not passing the kwsyntax. ++ + ## 5.0.9 (2021-05-16) + + Fixed a test breaking PyPy. Restored support for Sphinx. +diff --git a/src/decorator.py b/src/decorator.py +index 438dff6..dab0d7c 100644 +--- a/src/decorator.py ++++ b/src/decorator.py +@@ -265,7 +265,7 @@ def decorator(caller, _func=None, kwsyntax=False): + """ + if _func is not None: # return a decorated function + # this is obsolete behavior; you should use decorate instead +- return decorate(_func, caller) ++ return decorate(_func, caller, (), kwsyntax) + # else return a decorator function + sig = inspect.signature(caller) + dec_params = [p for p in sig.parameters.values() if p.kind is POS] diff --git a/python-decorator.changes b/python-decorator.changes index d987046..c7f8c56 100644 --- a/python-decorator.changes +++ b/python-decorator.changes @@ -1,3 +1,8 @@ +------------------------------------------------------------------- +Thu Aug 5 15:25:53 UTC 2021 - Markéta Machová + +- Add upstream patch kwsyntax.patch + ------------------------------------------------------------------- Tue Jul 27 06:15:15 UTC 2021 - Dirk Müller diff --git a/python-decorator.spec b/python-decorator.spec index 32a5c50..ee0ef01 100644 --- a/python-decorator.spec +++ b/python-decorator.spec @@ -28,6 +28,8 @@ License: BSD-2-Clause Group: Development/Languages/Python URL: https://github.com/micheles/decorator Source: https://files.pythonhosted.org/packages/source/d/decorator/decorator-%{version}.tar.gz +# PATCH-FIX-UPSTREAM https://github.com/micheles/decorator/commit/817d070db3c9cc5900d118837c533c039982b050 Fixed decorator.decorator not passing kwsyntax +Patch0: kwsyntax.patch BuildRequires: %{python_module setuptools} BuildRequires: dos2unix BuildRequires: fdupes @@ -46,6 +48,7 @@ redirecting_stdout, locked, etc. more accessible. %prep %setup -q -n decorator-%{version} +%autopatch -p1 %build %python_build