!11 [sync] PR-10: fix build error : modify setup.py get version class

From: @openeuler-sync-bot 
Reviewed-by: @lyn1001 
Signed-off-by: @lyn1001
This commit is contained in:
openeuler-ci-bot 2024-03-18 03:12:46 +00:00 committed by Gitee
commit 92afe6c9c2
No known key found for this signature in database
GPG Key ID: 173E9B9CA92EEF8F
2 changed files with 31 additions and 1 deletions

View File

@ -0,0 +1,26 @@
From de3ec76aba458b2b2ba58d1707dc9ecc82387eab Mon Sep 17 00:00:00 2001
From: yangchenguang <yangchenguang@kylinsec.com.cn>
Date: Thu, 14 Mar 2024 17:46:00 +0800
Subject: [PATCH] Modify late_version return to str
Signed-off-by: yangchenguang <yangchenguang@kylinsec.com.cn>
---
setup.py | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/setup.py b/setup.py
index 416afbe..fbaafa7 100755
--- a/setup.py
+++ b/setup.py
@@ -18,7 +18,7 @@ class late_version:
return str(self) + other
def replace(self, old, new):
return str(self).replace(old, new)
-VERSION = late_version()
+VERSION = str(late_version())
NAME = 'unittest2'
--
2.39.1

View File

@ -1,6 +1,6 @@
Name: python-unittest2
Version: 1.1.0
Release: 18
Release: 19
Summary: New features added to the unittest testing framework in Python 2.7 and onwards
License: BSD
URL: http://pypi.python.org/pypi/unittest2
@ -9,6 +9,7 @@ Source0: https://pypi.python.org/packages/source/u/unittest2/unittest2-%{
Patch0000: unittest2-1.1.0-remove-argparse-from-requires.patch
Patch0001: unittest2-1.1.0-backport-tests-from-py3.5.patch
Patch0002: fix-collections.MutableMapping-no-support-for-python-3.10.patch
Patch0003: Modify-late_version-return-to-str.patch
BuildArch: noarch
%description
@ -52,6 +53,9 @@ cd -
%{python3_sitelib}/unittest2*
%changelog
* Thu Mar 14 2024 yangchenguang <yangchenguang@kylinsec.com.cn> - 1.1.0-19
- fix build error : modify late_version return to str
* Tue Mar 22 2022 wulei <wulei80@huawei.com> - 1.1.0-18
- Fix collections.MutableMapping no support for python 3.10