Accepting request 981476 from home:pgajdos:python

- version update to 3.7.4
  * deps: require protobuf <4.0.0dev (#395) (6747720)
  * fix changelog header to consistent size (#396) (d4d2825)
  * fix type in docstring for map fields (3b845d6)
- added patches
  fix https://github.com/googleapis/python-translate/issues/403
  + python-google-cloud-translate-no-mock.patch

OBS-URL: https://build.opensuse.org/request/show/981476
OBS-URL: https://build.opensuse.org/package/show/devel:languages:python/python-google-cloud-translate?expand=0&rev=7
This commit is contained in:
Dirk Mueller 2022-06-09 15:18:05 +00:00 committed by Git OBS Bridge
parent 10310beab3
commit cb4b6a7e1d
5 changed files with 30 additions and 6 deletions

View File

@ -1,3 +0,0 @@
version https://git-lfs.github.com/spec/v1
oid sha256:89c646df71bf9e88a2f55d2bb074c6fd07bc70a0d50df01244acb65d160ce588
size 112023

View File

@ -0,0 +1,3 @@
version https://git-lfs.github.com/spec/v1
oid sha256:079301a5d712e8d37baf0be32f06d8e79ad5d1d2c3c16b6701a756b07d80c171
size 112657

View File

@ -0,0 +1,12 @@
diff -upr google-cloud-translate-3.7.4.orig/tests/unit/v2/test__http.py google-cloud-translate-3.7.4/tests/unit/v2/test__http.py
--- google-cloud-translate-3.7.4.orig/tests/unit/v2/test__http.py 2022-06-09 09:12:34.520648611 +0200
+++ google-cloud-translate-3.7.4/tests/unit/v2/test__http.py 2022-06-09 09:12:34.608649133 +0200
@@ -14,7 +14,7 @@
import unittest
-import mock
+from unittest import mock
class TestConnection(unittest.TestCase):

View File

@ -1,3 +1,14 @@
-------------------------------------------------------------------
Thu Jun 9 07:57:58 UTC 2022 - pgajdos@suse.com
- version update to 3.7.4
* deps: require protobuf <4.0.0dev (#395) (6747720)
* fix changelog header to consistent size (#396) (d4d2825)
* fix type in docstring for map fields (3b845d6)
- added patches
fix https://github.com/googleapis/python-translate/issues/403
+ python-google-cloud-translate-no-mock.patch
-------------------------------------------------------------------
Wed Apr 13 10:40:56 UTC 2022 - John Paul Adrian Glaubitz <adrian.glaubitz@suse.com>

View File

@ -19,18 +19,19 @@
%{?!python_module:%define python_module() python-%{**} python3-%{**}}
%define skip_python2 1
Name: python-google-cloud-translate
Version: 3.7.2
Version: 3.7.4
Release: 0
Summary: Google Cloud Translation API client library
License: Apache-2.0
URL: https://github.com/googleapis/python-translate
Source: https://files.pythonhosted.org/packages/source/g/google-cloud-translate/google-cloud-translate-%{version}.tar.gz
# https://github.com/googleapis/python-translate/issues/403
Patch0: python-google-cloud-translate-no-mock.patch
BuildRequires: %{python_module google-api-core >= 1.31.5}
BuildRequires: %{python_module google-cloud-core >= 1.3.0}
BuildRequires: %{python_module proto-plus >= 1.15.0}
BuildRequires: %{python_module setuptools}
# START TESTING SECTION
BuildRequires: %{python_module mock}
BuildRequires: %{python_module pytest-asyncio}
BuildRequires: %{python_module pytest}
# END TESTING SECTION
@ -50,7 +51,7 @@ thousands of language pairs. The Google Cloud Translation API lets websites
and programs integrate with Google Cloud Translation programmatically.
%prep
%setup -q -n google-cloud-translate-%{version}
%autosetup -p1 -n google-cloud-translate-%{version}
# add shebangs to installed scripts
sed -i '1i\#!%{__python3}' scripts/fixup_translate_v3_keywords.py
sed -i '1i\#!%{__python3}' scripts/fixup_translate_v3beta1_keywords.py