You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@libcloud.apache.org by to...@apache.org on 2015/04/06 12:02:41 UTC
[42/52] [abbrv] libcloud git commit: Re-order imports for consistency
reasons.
Re-order imports for consistency reasons.
Project: http://git-wip-us.apache.org/repos/asf/libcloud/repo
Commit: http://git-wip-us.apache.org/repos/asf/libcloud/commit/8b91a73c
Tree: http://git-wip-us.apache.org/repos/asf/libcloud/tree/8b91a73c
Diff: http://git-wip-us.apache.org/repos/asf/libcloud/diff/8b91a73c
Branch: refs/heads/trunk
Commit: 8b91a73ce5c7d5c2b298a56ce857cfa9c4947cbb
Parents: dce96e8
Author: Tomaz Muraus <to...@apache.org>
Authored: Sun Apr 5 13:39:13 2015 +0200
Committer: Tomaz Muraus <to...@apache.org>
Committed: Sun Apr 5 13:39:13 2015 +0200
----------------------------------------------------------------------
libcloud/compute/drivers/azure.py | 19 ++++++++++---------
1 file changed, 10 insertions(+), 9 deletions(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/libcloud/blob/8b91a73c/libcloud/compute/drivers/azure.py
----------------------------------------------------------------------
diff --git a/libcloud/compute/drivers/azure.py b/libcloud/compute/drivers/azure.py
index 4b2985b..15d44e5 100644
--- a/libcloud/compute/drivers/azure.py
+++ b/libcloud/compute/drivers/azure.py
@@ -23,6 +23,15 @@ import sys
import copy
import base64
+from datetime import datetime
+from xml.dom import minidom
+from xml.sax.saxutils import escape as xml_escape
+
+try:
+ from lxml import etree as ET
+except ImportError:
+ from xml.etree import ElementTree as ET
+
from libcloud.utils.py3 import urlquote as url_quote
from libcloud.common.azure import (AzureServiceManagementConnection,
AzureRedirectException)
@@ -32,18 +41,11 @@ from libcloud.compute.base import NodeImage, StorageVolume
from libcloud.compute.types import NodeState
from libcloud.common.types import LibcloudError
from libcloud.utils.py3 import httplib
+from libcloud.utils.py3 import urlparse
from libcloud.utils.py3 import ensure_string
-from datetime import datetime
-from xml.dom import minidom
-from xml.sax.saxutils import escape as xml_escape
HTTPSConnection = httplib.HTTPSConnection
-try:
- from lxml import etree as ET
-except ImportError:
- from xml.etree import ElementTree as ET
-
if sys.version_info < (3,):
_unicode_type = unicode
@@ -1283,7 +1285,6 @@ class AzureNodeDriver(NodeDriver):
)
except AzureRedirectException:
e = sys.exc_info()[1]
- from libcloud.utils.py3 import urlparse
parsed_url = urlparse.urlparse(e.location)
request.host = parsed_url.netloc
return self._perform_request(request)