support newst pyparsing syntax

(cherry picked from commit da70853a7a53a611d9382601912fad43089d58f6)
This commit is contained in:
bzg1107 2022-01-05 13:43:15 +08:00 committed by openeuler-sync-bot
parent 6d2c820891
commit 0e866e572d
2 changed files with 21 additions and 4 deletions

View File

@ -1,11 +1,25 @@
From bd95f5a96e11e917d26825eea7abf883174098f1 Mon Sep 17 00:00:00 2001
From 217b969872938cb021e914c202b8e09cf639c202 Mon Sep 17 00:00:00 2001
From: bzg1107 <preloyalwhite@163.com>
Date: Tue, 4 Jan 2022 16:02:44 +0800
Subject: [PATCH] cancel require pyparsing version limit
---
requirements.txt | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
python3/httplib2/auth.py | 2 +-
requirements.txt | 2 +-
2 files changed, 2 insertions(+), 2 deletions(-)
diff --git a/python3/httplib2/auth.py b/python3/httplib2/auth.py
index 516fdaa..9d9d7ed 100644
--- a/python3/httplib2/auth.py
+++ b/python3/httplib2/auth.py
@@ -15,7 +15,7 @@ token = pp.Word(tchar).setName("token")
token68 = pp.Combine(pp.Word("-._~+/" + pp.nums + pp.alphas) + pp.ZeroOrMore("=")).setName("token68")
quoted_string = pp.dblQuotedString.copy().setName("quoted-string").setParseAction(unquote)
-auth_param_name = token.copy().setName("auth-param-name").addParseAction(pp.downcaseTokens)
+auth_param_name = token.copy().setName("auth-param-name").addParseAction(pp.pyparsing_common.downcase_tokens)
auth_param = auth_param_name + pp.Suppress("=") + (token ^ quoted_string)
params = pp.Dict(pp.delimitedList(pp.Group(auth_param)))
diff --git a/requirements.txt b/requirements.txt
index 4ebe545..bc8d448 100644

View File

@ -1,6 +1,6 @@
Name: python-httplib2
Version: 0.19.0
Release: 3
Release: 4
Summary: Small, fast HTTP client library for Python.
License: MIT
URL: https://github.com/httplib2/httplib2
@ -56,6 +56,9 @@ popd
%endif
%changelog
* Mon Jan 9 2022 baizhonggui <baizhonggui@huawei.com> - 0.19.0-4
- support newst pyparsing syntax
* Sat Jan 8 2022 baizhonggui <baizhonggui@huawei.com> - 0.19.0-3
- fix require pyparsing version limit