mirror of
https://github.com/LukeHagar/vercel.git
synced 2025-12-06 21:07:47 +00:00
[python] Upgrade tests (#7711)
* [python] Upgrade tests * Fix latest sanic asgi * Bump flask * Change requirements.txt to Pipfile * Fix dev test * Use verbose requirements.txt * Flip requirements
This commit is contained in:
@@ -16,7 +16,7 @@ __vc_variables = dir(__vc_module)
|
||||
def format_headers(headers, decode=False):
|
||||
keyToList = {}
|
||||
for key, value in headers.items():
|
||||
if decode:
|
||||
if decode and 'decode' in dir(key) and 'decode' in dir(value):
|
||||
key = key.decode()
|
||||
value = value.decode()
|
||||
if key not in keyToList:
|
||||
@@ -102,7 +102,7 @@ elif 'app' in __vc_variables:
|
||||
if isinstance(s, str):
|
||||
s = s.encode(charset)
|
||||
return s.decode("latin1", errors)
|
||||
|
||||
|
||||
def vc_handler(event, context):
|
||||
payload = json.loads(event['body'])
|
||||
|
||||
|
||||
Reference in New Issue
Block a user