Permalink
Browse files

Updated all old-style inheritance calls.

  • Loading branch information...
1 parent 45e1884 commit 39a997fcd9eabc7b8114e2b5359669c16af4874a @toastdriven toastdriven committed Dec 20, 2013
Showing with 372 additions and 357 deletions.
  1. +1 −1 boto/auth.py
  2. +2 −2 boto/beanstalk/layer1.py
  3. +1 −1 boto/cloudformation/connection.py
  4. +1 −1 boto/cloudfront/__init__.py
  5. +5 −4 boto/cloudfront/distribution.py
  6. +4 −4 boto/cloudfront/object.py
  7. +1 −1 boto/cloudtrail/layer1.py
  8. +2 −2 boto/connection.py
  9. +2 −2 boto/contrib/ymlmessage.py
  10. +1 −1 boto/datapipeline/layer1.py
  11. +1 −1 boto/directconnect/layer1.py
  12. +1 −1 boto/dynamodb/layer1.py
  13. +1 −1 boto/dynamodb2/layer1.py
  14. +1 −1 boto/ec2/address.py
  15. +1 −1 boto/ec2/autoscale/__init__.py
  16. +5 −5 boto/ec2/bundleinstance.py
  17. +1 −1 boto/ec2/cloudwatch/__init__.py
  18. +1 −1 boto/ec2/connection.py
  19. +1 −1 boto/ec2/ec2object.py
  20. +1 −1 boto/ec2/elb/__init__.py
  21. +2 −2 boto/ec2/image.py
  22. +3 −3 boto/ec2/instance.py
  23. +1 −1 boto/ec2/keypair.py
  24. +1 −1 boto/ec2/launchspecification.py
  25. +3 −2 boto/ec2/networkinterface.py
  26. +1 −1 boto/ec2/placementgroup.py
  27. +3 −3 boto/ec2/regioninfo.py
  28. +6 −5 boto/ec2/reservedinstance.py
  29. +3 −2 boto/ec2/securitygroup.py
  30. +1 −1 boto/ec2/snapshot.py
  31. +1 −1 boto/ec2/spotdatafeedsubscription.py
  32. +3 −2 boto/ec2/spotinstancerequest.py
  33. +3 −3 boto/ec2/spotpricehistory.py
  34. +1 −1 boto/ec2/vmtype.py
  35. +2 −2 boto/ec2/volume.py
  36. +5 −5 boto/ec2/zone.py
  37. +5 −5 boto/ecs/__init__.py
  38. +6 −6 boto/ecs/item.py
  39. +1 −1 boto/elasticache/layer1.py
  40. +3 −3 boto/elastictranscoder/layer1.py
  41. +1 −1 boto/emr/connection.py
  42. +5 −5 boto/emr/step.py
  43. +24 −22 boto/exception.py
  44. +1 −1 boto/fps/connection.py
  45. +25 −17 boto/fps/response.py
  46. +2 −2 boto/glacier/layer1.py
  47. +6 −6 boto/gs/connection.py
  48. +1 −2 boto/iam/connection.py
  49. +1 −1 boto/kinesis/layer1.py
  50. +24 −24 boto/manage/server.py
  51. +11 −11 boto/manage/task.py
  52. +7 −7 boto/manage/volume.py
  53. +5 −5 boto/mashups/server.py
  54. +6 −6 boto/mturk/connection.py
  55. +8 −8 boto/mturk/qualification.py
  56. +1 −1 boto/mws/connection.py
  57. +13 −13 boto/mws/response.py
  58. +2 −2 boto/opsworks/layer1.py
  59. +2 −2 boto/pyami/bootstrap.py
  60. +2 −0 boto/pyami/config.py
  61. +4 −4 boto/pyami/copybot.py
  62. +7 −7 boto/pyami/installers/ubuntu/ebs.py
  63. +10 −10 boto/rds/__init__.py
  64. +2 −2 boto/rds/regioninfo.py
  65. +1 −1 boto/redshift/layer1.py
  66. +13 −13 boto/roboto/awsqueryrequest.py
  67. +4 −4 boto/roboto/awsqueryservice.py
  68. +7 −7 boto/roboto/param.py
  69. +2 −2 boto/route53/connection.py
  70. +3 −3 boto/route53/record.py
  71. +1 −1 boto/s3/connection.py
  72. +2 −2 boto/sdb/connection.py
  73. +31 −31 boto/sdb/db/property.py
  74. +1 −1 boto/sdb/domain.py
  75. +2 −2 boto/sdb/regioninfo.py
  76. +3 −3 boto/services/service.py
  77. +9 −9 boto/services/servicedef.py
  78. +3 −3 boto/services/sonofmmm.py
  79. +1 −1 boto/ses/connection.py
  80. +2 −2 boto/sns/connection.py
  81. +4 −4 boto/sqs/bigmessage.py
  82. +1 −1 boto/sqs/connection.py
  83. +3 −3 boto/sqs/message.py
  84. +2 −2 boto/sqs/regioninfo.py
  85. +1 −1 boto/sts/connection.py
  86. +1 −1 boto/support/layer1.py
  87. +1 −1 boto/swf/layer1.py
  88. +1 −1 boto/utils.py
  89. +1 −1 boto/vpc/customergateway.py
  90. +6 −6 boto/vpc/dhcpoptions.py
  91. +1 −1 boto/vpc/internetgateway.py
  92. +1 −1 boto/vpc/networkacl.py
  93. +1 −1 boto/vpc/routetable.py
  94. +1 −1 boto/vpc/subnet.py
  95. +1 −1 boto/vpc/vpc.py
  96. +1 −1 boto/vpc/vpnconnection.py
  97. +2 −2 boto/vpc/vpngateway.py
  98. +0 −1 tests/unit/ec2/test_volume.py
View
@@ -109,7 +109,7 @@ class AnonAuthHandler(AuthHandler, HmacKeys):
capability = ['anon']
def __init__(self, host, config, provider):
- AuthHandler.__init__(self, host, config, provider)
+ super(AnonAuthHandler, self).__init__(host, config, provider)
def add_auth(self, http_request, **kwargs):
pass
View
@@ -45,7 +45,7 @@ def __init__(self, aws_access_key_id=None, aws_secret_access_key=None,
region = RegionInfo(self, self.DefaultRegionName,
self.DefaultRegionEndpoint)
self.region = region
- AWSQueryConnection.__init__(self, aws_access_key_id,
+ super(Layer1, self).__init__(aws_access_key_id,
aws_secret_access_key,
is_secure, port, proxy, proxy_port,
proxy_user, proxy_pass,
@@ -1116,7 +1116,7 @@ def update_environment(self, environment_id=None, environment_name=None,
:type tier_version: string
:type tier_version: The version of the tier. Valid values
currently are "1.0". Defaults to "1.0".
-
+
:raises: InsufficientPrivilegesException
"""
params = {}
@@ -57,7 +57,7 @@ def __init__(self, aws_access_key_id=None, aws_secret_access_key=None,
region = RegionInfo(self, self.DefaultRegionName,
self.DefaultRegionEndpoint, CloudFormationConnection)
self.region = region
- AWSQueryConnection.__init__(self, aws_access_key_id,
+ super(CloudFormationConnection, self).__init__(aws_access_key_id,
aws_secret_access_key,
is_secure, port, proxy, proxy_port,
proxy_user, proxy_pass,
@@ -44,7 +44,7 @@ def __init__(self, aws_access_key_id=None, aws_secret_access_key=None,
port=None, proxy=None, proxy_port=None,
host=DefaultHost, debug=0, security_token=None,
validate_certs=True):
- AWSAuthConnection.__init__(self, host,
+ super(CloudFrontConnection, self).__init__(host,
aws_access_key_id, aws_secret_access_key,
True, port, proxy, proxy_port, debug=debug,
security_token=security_token,
@@ -176,7 +176,7 @@ class StreamingDistributionConfig(DistributionConfig):
def __init__(self, connection=None, origin='', enabled=False,
caller_reference='', cnames=None, comment='',
trusted_signers=None, logging=None):
- DistributionConfig.__init__(self, connection=connection,
+ super(StreamingDistributionConfig, self).__init__(connection=connection,
origin=origin, enabled=enabled,
caller_reference=caller_reference,
cnames=cnames, comment=comment,
@@ -684,16 +684,17 @@ class StreamingDistribution(Distribution):
def __init__(self, connection=None, config=None, domain_name='',
id='', last_modified_time=None, status=''):
- Distribution.__init__(self, connection, config, domain_name,
- id, last_modified_time, status)
+ super(StreamingDistribution, self).__init__(connection, config,
+ domain_name, id, last_modified_time, status)
self._object_class = StreamingObject
def startElement(self, name, attrs, connection):
if name == 'StreamingDistributionConfig':
self.config = StreamingDistributionConfig()
return self.config
else:
- return Distribution.startElement(self, name, attrs, connection)
+ return super(StreamingDistribution, self).startElement(name, attrs,
+ connection)
def update(self, enabled=None, cnames=None, comment=None):
"""
@@ -14,7 +14,7 @@
# THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS
# OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABIL-
# ITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT
-# SHALL THE AUTHOR BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY,
+# SHALL THE AUTHOR BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY,
# WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
# OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS
# IN THE SOFTWARE.
@@ -24,7 +24,7 @@
class Object(Key):
def __init__(self, bucket, name=None):
- Key.__init__(self, bucket, name=name)
+ super(Object, self).__init__(bucket, name=name)
self.distribution = bucket.distribution
def __repr__(self):
@@ -43,6 +43,6 @@ def url(self, scheme='http'):
class StreamingObject(Object):
def url(self, scheme='rtmp'):
- return Object.url(self, scheme)
+ return super(StreamingObject, self).url(scheme)
+
-
@@ -90,7 +90,7 @@ def __init__(self, **kwargs):
if 'host' not in kwargs:
kwargs['host'] = region.endpoint
- AWSQueryConnection.__init__(self, **kwargs)
+ super(CloudTrailConnection, self).__init__(**kwargs)
self.region = region
def _required_auth_capability(self):
View
@@ -888,7 +888,7 @@ def _mexe(self, request, sender=None, override_num_retries=None,
# not include the port.
if 's3' not in self._required_auth_capability():
self.set_host_header(request)
-
+
if callable(sender):
response = sender(connection, request.method, request.path,
request.body, request.headers)
@@ -1034,7 +1034,7 @@ def __init__(self, aws_access_key_id=None, aws_secret_access_key=None,
proxy_user=None, proxy_pass=None, host=None, debug=0,
https_connection_factory=None, path='/', security_token=None,
validate_certs=True):
- AWSAuthConnection.__init__(self, host, aws_access_key_id,
+ super(AWSQueryConnection, self).__init__(host, aws_access_key_id,
aws_secret_access_key,
is_secure, port, proxy,
proxy_port, proxy_user, proxy_pass,
@@ -14,7 +14,7 @@
# THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS
# OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABIL-
# ITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT
-# SHALL THE AUTHOR BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY,
+# SHALL THE AUTHOR BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY,
# WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
# OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS
# IN THE SOFTWARE.
@@ -43,7 +43,7 @@ class YAMLMessage(Message):
def __init__(self, queue=None, body='', xml_attrs=None):
self.data = None
- Message.__init__(self, queue, body)
+ super(YAMLMessage, self).__init__(queue, body)
def set_body(self, body):
self.data = yaml.load(body)
@@ -90,7 +90,7 @@ def __init__(self, **kwargs):
region = RegionInfo(self, self.DefaultRegionName,
self.DefaultRegionEndpoint)
kwargs['host'] = region.endpoint
- AWSQueryConnection.__init__(self, **kwargs)
+ super(DataPipelineConnection, self).__init__(**kwargs)
self.region = region
def _required_auth_capability(self):
@@ -79,7 +79,7 @@ def __init__(self, **kwargs):
if 'host' not in kwargs:
kwargs['host'] = region.endpoint
- AWSQueryConnection.__init__(self, **kwargs)
+ super(DirectConnectConnection, self).__init__(**kwargs)
self.region = region
def _required_auth_capability(self):
View
@@ -84,7 +84,7 @@ def __init__(self, aws_access_key_id=None, aws_secret_access_key=None,
break
self.region = region
- AWSAuthConnection.__init__(self, self.region.endpoint,
+ super(Layer1, self).__init__(self.region.endpoint,
aws_access_key_id,
aws_secret_access_key,
is_secure, port, proxy, proxy_port,
View
@@ -75,7 +75,7 @@ def __init__(self, **kwargs):
if 'host' not in kwargs:
kwargs['host'] = region.endpoint
- AWSQueryConnection.__init__(self, **kwargs)
+ super(DynamoDBConnection, self).__init__(**kwargs)
self.region = region
self._validate_checksums = boto.config.getbool(
'DynamoDB', 'validate_checksums', validate_checksums)
View
@@ -37,7 +37,7 @@ class Address(EC2Object):
"""
def __init__(self, connection=None, public_ip=None, instance_id=None):
- EC2Object.__init__(self, connection)
+ super(Address, self).__init__(connection)
self.connection = connection
self.public_ip = public_ip
self.instance_id = instance_id
@@ -114,7 +114,7 @@ def __init__(self, aws_access_key_id=None, aws_secret_access_key=None,
self.DefaultRegionEndpoint,
AutoScaleConnection)
self.region = region
- AWSQueryConnection.__init__(self, aws_access_key_id,
+ super(AutoScaleConnection, self).__init__(aws_access_key_id,
aws_secret_access_key,
is_secure, port, proxy, proxy_port,
proxy_user, proxy_pass,
View
@@ -14,21 +14,21 @@
# THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS
# OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABIL-
# ITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT
-# SHALL THE AUTHOR BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY,
+# SHALL THE AUTHOR BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY,
# WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
# OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS
# IN THE SOFTWARE.
"""
-Represents an EC2 Bundle Task
+Represents an EC2 Bundle Task
"""
from boto.ec2.ec2object import EC2Object
class BundleInstanceTask(EC2Object):
-
+
def __init__(self, connection=None):
- EC2Object.__init__(self, connection)
+ super(BundleInstanceTask, self).__init__(connection)
self.id = None
self.instance_id = None
self.progress = None
@@ -38,7 +38,7 @@ def __init__(self, connection=None):
self.prefix = None
self.upload_policy = None
self.upload_policy_signature = None
- self.update_time = None
+ self.update_time = None
self.code = None
self.message = None
@@ -107,7 +107,7 @@ def __init__(self, aws_access_key_id=None, aws_secret_access_key=None,
if self.region.name == 'eu-west-1':
validate_certs = False
- AWSQueryConnection.__init__(self, aws_access_key_id,
+ super(CloudWatchConnection, self).__init__(aws_access_key_id,
aws_secret_access_key,
is_secure, port, proxy, proxy_port,
proxy_user, proxy_pass,
View
@@ -91,7 +91,7 @@ def __init__(self, aws_access_key_id=None, aws_secret_access_key=None,
region = RegionInfo(self, self.DefaultRegionName,
self.DefaultRegionEndpoint)
self.region = region
- AWSQueryConnection.__init__(self, aws_access_key_id,
+ super(EC2Connection, self).__init__(aws_access_key_id,
aws_secret_access_key,
is_secure, port, proxy, proxy_port,
proxy_user, proxy_pass,
View
@@ -53,7 +53,7 @@ class TaggedEC2Object(EC2Object):
"""
def __init__(self, connection=None):
- EC2Object.__init__(self, connection)
+ super(TaggedEC2Object, self).__init__(connection)
self.tags = TagSet()
def startElement(self, name, attrs, connection):
View
@@ -102,7 +102,7 @@ def __init__(self, aws_access_key_id=None, aws_secret_access_key=None,
region = RegionInfo(self, self.DefaultRegionName,
self.DefaultRegionEndpoint)
self.region = region
- AWSQueryConnection.__init__(self, aws_access_key_id,
+ super(ELBConnection, self).__init__(aws_access_key_id,
aws_secret_access_key,
is_secure, port, proxy, proxy_port,
proxy_user, proxy_pass,
View
@@ -47,7 +47,7 @@ class Image(TaggedEC2Object):
"""
def __init__(self, connection=None):
- TaggedEC2Object.__init__(self, connection)
+ super(Image, self).__init__(connection)
self.id = None
self.location = None
self.state = None
@@ -75,7 +75,7 @@ def __repr__(self):
return 'Image:%s' % self.id
def startElement(self, name, attrs, connection):
- retval = TaggedEC2Object.startElement(self, name, attrs, connection)
+ retval = super(Image, self).startElement(name, attrs, connection)
if retval is not None:
return retval
if name == 'blockDeviceMapping':
View
@@ -122,7 +122,7 @@ class Reservation(EC2Object):
Reservation.
"""
def __init__(self, connection=None):
- EC2Object.__init__(self, connection)
+ super(Reservation, self).__init__(connection)
self.id = None
self.owner_id = None
self.groups = []
@@ -211,7 +211,7 @@ class Instance(TaggedEC2Object):
"""
def __init__(self, connection=None):
- TaggedEC2Object.__init__(self, connection)
+ super(Instance, self).__init__(connection)
self.id = None
self.dns_name = None
self.public_dns_name = None
@@ -288,7 +288,7 @@ def placement_tenancy(self):
return self._placement.tenancy
def startElement(self, name, attrs, connection):
- retval = TaggedEC2Object.startElement(self, name, attrs, connection)
+ retval = super(Instance, self).startElement(name, attrs, connection)
if retval is not None:
return retval
if name == 'monitoring':
View
@@ -30,7 +30,7 @@
class KeyPair(EC2Object):
def __init__(self, connection=None):
- EC2Object.__init__(self, connection)
+ super(KeyPair, self).__init__(connection)
self.name = None
self.fingerprint = None
self.material = None
@@ -44,7 +44,7 @@ def endElement(self, name, value, connection):
class LaunchSpecification(EC2Object):
def __init__(self, connection=None):
- EC2Object.__init__(self, connection)
+ super(LaunchSpecification, self).__init__(connection)
self.key_name = None
self.instance_type = None
self.image_id = None
@@ -99,7 +99,7 @@ class NetworkInterface(TaggedEC2Object):
"""
def __init__(self, connection=None):
- TaggedEC2Object.__init__(self, connection)
+ super(NetworkInterface, self).__init__(connection)
self.id = None
self.subnet_id = None
self.vpc_id = None
@@ -119,7 +119,8 @@ def __repr__(self):
return 'NetworkInterface:%s' % self.id
def startElement(self, name, attrs, connection):
- retval = TaggedEC2Object.startElement(self, name, attrs, connection)
+ retval = super(NetworkInterface, self).startElement(name, attrs,
+ connection)
if retval is not None:
return retval
if name == 'groupSet':
@@ -27,7 +27,7 @@
class PlacementGroup(EC2Object):
def __init__(self, connection=None, name=None, strategy=None, state=None):
- EC2Object.__init__(self, connection)
+ super(PlacementGroup, self).__init__(connection)
self.name = name
self.strategy = strategy
self.state = state
View
@@ -16,7 +16,7 @@
# THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS
# OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABIL-
# ITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT
-# SHALL THE AUTHOR BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY,
+# SHALL THE AUTHOR BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY,
# WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
# OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS
# IN THE SOFTWARE.
@@ -27,8 +27,8 @@ class EC2RegionInfo(RegionInfo):
"""
Represents an EC2 Region
"""
-
+
def __init__(self, connection=None, name=None, endpoint=None):
from boto.ec2.connection import EC2Connection
- RegionInfo.__init__(self, connection, name, endpoint,
+ super(EC2RegionInfo, self).__init__(connection, name, endpoint,
EC2Connection)
Oops, something went wrong.

0 comments on commit 39a997f

Please sign in to comment.