Ran 2to3 on pillar + some manual fixups
The 'manual fixups' are: - incorrect use of dict.items() where dict.iteritems() was meant; this results in list(dict.items()), which I changed to dict.items(). - removal of 'from __future__ import' lines, which 2to3 changes into empty lines; I removed the empty lines.
This commit is contained in:
@@ -1,7 +1,7 @@
|
||||
"""PillarSDK subclass for direct Flask-internal calls."""
|
||||
|
||||
import logging
|
||||
import urlparse
|
||||
import urllib.parse
|
||||
from flask import current_app
|
||||
|
||||
import pillarsdk
|
||||
@@ -23,8 +23,8 @@ class FlaskInternalApi(pillarsdk.Api):
|
||||
self.requests_to_flask_kwargs(kwargs)
|
||||
|
||||
# Leave out the query string and fragment from the URL.
|
||||
split_url = urlparse.urlsplit(url)
|
||||
path = urlparse.urlunsplit(split_url[:-2] + (None, None))
|
||||
split_url = urllib.parse.urlsplit(url)
|
||||
path = urllib.parse.urlunsplit(split_url[:-2] + (None, None))
|
||||
try:
|
||||
response = client.open(path=path, query_string=split_url.query, method=method,
|
||||
**kwargs)
|
||||
|
Reference in New Issue
Block a user