libcloud-notifications mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From to...@apache.org
Subject svn commit: r1337772 - in /libcloud/trunk/libcloud: common/ compute/drivers/ dns/drivers/ loadbalancer/drivers/ storage/drivers/ utils/
Date Sun, 13 May 2012 04:15:57 GMT
Author: tomaz
Date: Sun May 13 04:15:56 2012
New Revision: 1337772

URL: http://svn.apache.org/viewvc?rev=1337772&view=rev
Log:
More pyflakes fixes.

Modified:
    libcloud/trunk/libcloud/common/openstack.py
    libcloud/trunk/libcloud/compute/drivers/bluebox.py
    libcloud/trunk/libcloud/compute/drivers/brightbox.py
    libcloud/trunk/libcloud/compute/drivers/joyent.py
    libcloud/trunk/libcloud/compute/drivers/libvirt_driver.py
    libcloud/trunk/libcloud/compute/drivers/linode.py
    libcloud/trunk/libcloud/compute/drivers/openstack.py
    libcloud/trunk/libcloud/compute/drivers/vcl.py
    libcloud/trunk/libcloud/compute/drivers/vcloud.py
    libcloud/trunk/libcloud/dns/drivers/linode.py
    libcloud/trunk/libcloud/loadbalancer/drivers/brightbox.py
    libcloud/trunk/libcloud/loadbalancer/drivers/rackspace.py
    libcloud/trunk/libcloud/storage/drivers/cloudfiles.py
    libcloud/trunk/libcloud/storage/drivers/nimbus.py
    libcloud/trunk/libcloud/utils/compression.py

Modified: libcloud/trunk/libcloud/common/openstack.py
URL: http://svn.apache.org/viewvc/libcloud/trunk/libcloud/common/openstack.py?rev=1337772&r1=1337771&r2=1337772&view=diff
==============================================================================
--- libcloud/trunk/libcloud/common/openstack.py (original)
+++ libcloud/trunk/libcloud/common/openstack.py Sun May 13 04:15:56 2012
@@ -21,7 +21,6 @@ import binascii
 import os
 
 from libcloud.utils.py3 import httplib
-from libcloud.utils.py3 import urlparse
 
 from libcloud.common.base import ConnectionUserAndKey, Response
 from libcloud.compute.types import (LibcloudError, InvalidCredsError,

Modified: libcloud/trunk/libcloud/compute/drivers/bluebox.py
URL: http://svn.apache.org/viewvc/libcloud/trunk/libcloud/compute/drivers/bluebox.py?rev=1337772&r1=1337771&r2=1337772&view=diff
==============================================================================
--- libcloud/trunk/libcloud/compute/drivers/bluebox.py (original)
+++ libcloud/trunk/libcloud/compute/drivers/bluebox.py Sun May 13 04:15:56 2012
@@ -23,7 +23,6 @@ Blue Box API documentation    https://bo
 """
 
 import copy
-from libcloud.utils.py3 import urllib
 import base64
 
 from libcloud.utils.py3 import urlencode

Modified: libcloud/trunk/libcloud/compute/drivers/brightbox.py
URL: http://svn.apache.org/viewvc/libcloud/trunk/libcloud/compute/drivers/brightbox.py?rev=1337772&r1=1337771&r2=1337772&view=diff
==============================================================================
--- libcloud/trunk/libcloud/compute/drivers/brightbox.py (original)
+++ libcloud/trunk/libcloud/compute/drivers/brightbox.py Sun May 13 04:15:56 2012
@@ -18,7 +18,6 @@ Brightbox Driver
 
 from libcloud.utils.py3 import httplib
 from libcloud.utils.py3 import b
-from libcloud.utils.py3 import u
 
 from libcloud.common.brightbox import BrightboxConnection
 from libcloud.compute.types import Provider, NodeState

Modified: libcloud/trunk/libcloud/compute/drivers/joyent.py
URL: http://svn.apache.org/viewvc/libcloud/trunk/libcloud/compute/drivers/joyent.py?rev=1337772&r1=1337771&r2=1337772&view=diff
==============================================================================
--- libcloud/trunk/libcloud/compute/drivers/joyent.py (original)
+++ libcloud/trunk/libcloud/compute/drivers/joyent.py Sun May 13 04:15:56 2012
@@ -134,7 +134,6 @@ class JoyentNodeDriver(NodeDriver):
         return result.status == httplib.ACCEPTED
 
     def destroy_node(self, node):
-        data = json.dumps({'action': 'reboot'})
         result = self.connection.request('/my/machines/%s' % (node.id),
                                          method='DELETE')
         return result.status == httplib.NO_CONTENT

Modified: libcloud/trunk/libcloud/compute/drivers/libvirt_driver.py
URL: http://svn.apache.org/viewvc/libcloud/trunk/libcloud/compute/drivers/libvirt_driver.py?rev=1337772&r1=1337771&r2=1337772&view=diff
==============================================================================
--- libcloud/trunk/libcloud/compute/drivers/libvirt_driver.py (original)
+++ libcloud/trunk/libcloud/compute/drivers/libvirt_driver.py Sun May 13 04:15:56 2012
@@ -13,8 +13,8 @@
 # See the License for the specific language governing permissions and
 # limitations under the License.
 
-from libcloud.compute.base import NodeDriver, NodeSize, Node
-from libcloud.compute.base import NodeImage, NodeState
+from libcloud.compute.base import NodeDriver, Node
+from libcloud.compute.base import NodeState
 from libcloud.compute.types import Provider
 
 try:

Modified: libcloud/trunk/libcloud/compute/drivers/linode.py
URL: http://svn.apache.org/viewvc/libcloud/trunk/libcloud/compute/drivers/linode.py?rev=1337772&r1=1337771&r2=1337772&view=diff
==============================================================================
--- libcloud/trunk/libcloud/compute/drivers/linode.py (original)
+++ libcloud/trunk/libcloud/compute/drivers/linode.py Sun May 13 04:15:56 2012
@@ -28,7 +28,6 @@ Linode(R) is a registered trademark of L
 """
 
 import os
-import hashlib
 
 try:
     import simplejson as json
@@ -41,7 +40,6 @@ import binascii
 from copy import copy
 
 from libcloud.utils.py3 import PY3
-from libcloud.utils.py3 import u
 
 from libcloud.common.linode import (API_ROOT, LinodeException, LinodeConnection,
     LINODE_PLAN_IDS)

Modified: libcloud/trunk/libcloud/compute/drivers/openstack.py
URL: http://svn.apache.org/viewvc/libcloud/trunk/libcloud/compute/drivers/openstack.py?rev=1337772&r1=1337771&r2=1337772&view=diff
==============================================================================
--- libcloud/trunk/libcloud/compute/drivers/openstack.py (original)
+++ libcloud/trunk/libcloud/compute/drivers/openstack.py Sun May 13 04:15:56 2012
@@ -16,15 +16,11 @@
 OpenStack driver
 """
 
-import binascii
-
 try:
     import simplejson as json
 except ImportError:
     import json
 
-import os
-
 import warnings
 
 from itertools import chain
@@ -40,7 +36,7 @@ from xml.etree import ElementTree as ET
 
 from libcloud.common.openstack import OpenStackBaseConnection
 from libcloud.common.openstack import OpenStackDriverMixin
-from libcloud.common.types import MalformedResponseError, LibcloudError
+from libcloud.common.types import MalformedResponseError
 from libcloud.compute.types import NodeState, Provider
 from libcloud.compute.base import NodeSize, NodeImage
 from libcloud.compute.base import NodeDriver, Node, NodeLocation

Modified: libcloud/trunk/libcloud/compute/drivers/vcl.py
URL: http://svn.apache.org/viewvc/libcloud/trunk/libcloud/compute/drivers/vcl.py?rev=1337772&r1=1337771&r2=1337772&view=diff
==============================================================================
--- libcloud/trunk/libcloud/compute/drivers/vcl.py (original)
+++ libcloud/trunk/libcloud/compute/drivers/vcl.py Sun May 13 04:15:56 2012
@@ -19,13 +19,12 @@ VCL driver
 import sys
 import time
 
-import libcloud
 from libcloud.utils.py3 import xmlrpclib
 
 from libcloud.common.types import InvalidCredsError, LibcloudError
 from libcloud.compute.types import Provider, NodeState
 from libcloud.compute.base import NodeDriver, Node
-from libcloud.compute.base import NodeLocation, NodeSize, NodeImage
+from libcloud.compute.base import NodeSize, NodeImage
 
 
 class VCLSafeTransport(xmlrpclib.SafeTransport):
@@ -187,7 +186,7 @@ class VCLNodeDriver(NodeDriver):
         Throws error if request fails.
         """
         try:
-            res = self._vcl_request(
+            self._vcl_request(
                 'XMLRPCendRequest',
                 node.id
             )

Modified: libcloud/trunk/libcloud/compute/drivers/vcloud.py
URL: http://svn.apache.org/viewvc/libcloud/trunk/libcloud/compute/drivers/vcloud.py?rev=1337772&r1=1337771&r2=1337772&view=diff
==============================================================================
--- libcloud/trunk/libcloud/compute/drivers/vcloud.py (original)
+++ libcloud/trunk/libcloud/compute/drivers/vcloud.py Sun May 13 04:15:56 2012
@@ -992,7 +992,6 @@ class VCloud_1_5_NodeDriver(VCloudNodeDr
         """
         name = kwargs['name']
         image = kwargs['image']
-        size = kwargs.get('size', None)
         ex_vm_names = kwargs.get('ex_vm_names')
         ex_vm_cpu = kwargs.get('ex_vm_cpu')
         ex_vm_memory = kwargs.get('ex_vm_memory')

Modified: libcloud/trunk/libcloud/dns/drivers/linode.py
URL: http://svn.apache.org/viewvc/libcloud/trunk/libcloud/dns/drivers/linode.py?rev=1337772&r1=1337771&r2=1337772&view=diff
==============================================================================
--- libcloud/trunk/libcloud/dns/drivers/linode.py (original)
+++ libcloud/trunk/libcloud/dns/drivers/linode.py Sun May 13 04:15:56 2012
@@ -21,7 +21,6 @@ __all__ = [
 from libcloud.utils.misc import merge_valid_keys, get_new_obj
 from libcloud.common.linode import (API_ROOT, LinodeException,
                                     LinodeConnection, LinodeResponse)
-from libcloud.common.linode import API_ROOT, LinodeException
 from libcloud.dns.types import Provider, RecordType
 from libcloud.dns.types import ZoneDoesNotExistError, RecordDoesNotExistError
 from libcloud.dns.base import DNSDriver, Zone, Record
@@ -197,7 +196,7 @@ class LinodeDNSDriver(DNSDriver):
                                   valid_keys=VALID_RECORD_EXTRA_PARAMS,
                                   extra=extra)
 
-        result = self.connection.request(API_ROOT, params=params).objects[0]
+        self.connection.request(API_ROOT, params=params).objects[0]
         updated_record = get_new_obj(obj=record, klass=Record,
                                      attributes={'name': name, 'data': data,
                                                  'type': type,

Modified: libcloud/trunk/libcloud/loadbalancer/drivers/brightbox.py
URL: http://svn.apache.org/viewvc/libcloud/trunk/libcloud/loadbalancer/drivers/brightbox.py?rev=1337772&r1=1337771&r2=1337772&view=diff
==============================================================================
--- libcloud/trunk/libcloud/loadbalancer/drivers/brightbox.py (original)
+++ libcloud/trunk/libcloud/loadbalancer/drivers/brightbox.py Sun May 13 04:15:56 2012
@@ -84,7 +84,7 @@ class BrightboxLBDriver(Driver):
     def balancer_attach_member(self, balancer, member):
         path = '/%s/load_balancers/%s/add_nodes' % (API_VERSION, balancer.id)
 
-        response = self._post(path, {'nodes': [self._member_to_node(member)]})
+        self._post(path, {'nodes': [self._member_to_node(member)]})
 
         return member
 
@@ -130,3 +130,5 @@ class BrightboxLBDriver(Driver):
             ip = data['cloud_ips'][0]['public_ip']
         else:
             ip = None
+
+        return ip

Modified: libcloud/trunk/libcloud/loadbalancer/drivers/rackspace.py
URL: http://svn.apache.org/viewvc/libcloud/trunk/libcloud/loadbalancer/drivers/rackspace.py?rev=1337772&r1=1337771&r2=1337772&view=diff
==============================================================================
--- libcloud/trunk/libcloud/loadbalancer/drivers/rackspace.py (original)
+++ libcloud/trunk/libcloud/loadbalancer/drivers/rackspace.py Sun May 13 04:15:56 2012
@@ -13,8 +13,6 @@
 # See the License for the specific language governing permissions and
 # limitations under the License.
 
-import os
-import binascii
 from datetime import datetime
 
 try:

Modified: libcloud/trunk/libcloud/storage/drivers/cloudfiles.py
URL: http://svn.apache.org/viewvc/libcloud/trunk/libcloud/storage/drivers/cloudfiles.py?rev=1337772&r1=1337771&r2=1337772&view=diff
==============================================================================
--- libcloud/trunk/libcloud/storage/drivers/cloudfiles.py (original)
+++ libcloud/trunk/libcloud/storage/drivers/cloudfiles.py Sun May 13 04:15:56 2012
@@ -14,7 +14,6 @@
 # limitations under the License.
 
 import os
-import math
 
 from libcloud.utils.py3 import httplib
 

Modified: libcloud/trunk/libcloud/storage/drivers/nimbus.py
URL: http://svn.apache.org/viewvc/libcloud/trunk/libcloud/storage/drivers/nimbus.py?rev=1337772&r1=1337771&r2=1337772&view=diff
==============================================================================
--- libcloud/trunk/libcloud/storage/drivers/nimbus.py (original)
+++ libcloud/trunk/libcloud/storage/drivers/nimbus.py Sun May 13 04:15:56 2012
@@ -13,7 +13,6 @@
 # See the License for the specific language governing permissions and
 # limitations under the License.
 
-import os
 import time
 import hashlib
 import hmac
@@ -28,7 +27,7 @@ from libcloud.utils.py3 import urlencode
 
 from libcloud.common.base import ConnectionUserAndKey, JsonResponse
 from libcloud.common.types import InvalidCredsError, LibcloudError
-from libcloud.storage.base import Object, Container, StorageDriver
+from libcloud.storage.base import Container, StorageDriver
 
 
 class NimbusResponse(JsonResponse):

Modified: libcloud/trunk/libcloud/utils/compression.py
URL: http://svn.apache.org/viewvc/libcloud/trunk/libcloud/utils/compression.py?rev=1337772&r1=1337771&r2=1337772&view=diff
==============================================================================
--- libcloud/trunk/libcloud/utils/compression.py (original)
+++ libcloud/trunk/libcloud/utils/compression.py Sun May 13 04:15:56 2012
@@ -18,7 +18,6 @@ import gzip
 
 from libcloud.utils.py3 import PY3
 from libcloud.utils.py3 import StringIO
-from libcloud.utils.py3 import b
 
 
 __all__ = [



Mime
View raw message