]> review.fuel-infra Code Review - openstack-build/heat-build.git/commitdiff
Fix PEP H101 (Use TODO(NAME))
authorAngus Salkeld <asalkeld@redhat.com>
Mon, 20 May 2013 06:11:17 +0000 (16:11 +1000)
committerAngus Salkeld <asalkeld@redhat.com>
Tue, 21 May 2013 11:15:33 +0000 (21:15 +1000)
Change-Id: I77c9caa650462725b7c686fbafd9753d046b138d

heat/api/cfn/v1/stacks.py
heat/cfn_client/boto_client_cloudwatch.py
heat/engine/resources/internet_gateway.py
heat/engine/resources/route_table.py
heat/engine/resources/subnet.py
heat/engine/resources/user.py
heat/tests/test_api_cfn_v1.py
heat/tests/test_eip.py
tox.ini

index 959a756df13ffaed5716b51b9ca4be28615de591..7ca8ef670882c4fc32483a14421419c4f06e2900 100644 (file)
@@ -133,7 +133,7 @@ class StackController(object):
             result = api_utils.reformat_dict_keys(keymap, s)
 
             # AWS docs indicate DeletionTime is ommitted for current stacks
-            # This is still TODO in the engine, we don't keep data for
+            # This is still TODO(unknown) in the engine, we don't keep data for
             # stacks after they are deleted
             if engine_api.STACK_DELETION_TIME in s:
                 result['DeletionTime'] = s[engine_api.STACK_DELETION_TIME]
@@ -279,7 +279,7 @@ class StackController(object):
             the engine API.  FIXME: we currently only support a subset of
             the AWS defined parameters (both here and in the engine)
             """
-            # TODO : Capabilities, NotificationARNs
+            # TODO(shardy) : Capabilities, NotificationARNs
             keymap = {'TimeoutInMinutes': engine_api.PARAM_TIMEOUT,
                       'DisableRollback': engine_api.PARAM_DISABLE_ROLLBACK}
 
index 98a14c468214b6dc9c172477f443507b189fff91..ed72b2db6901cfd558c23367e9f05354ac5a7141 100644 (file)
@@ -29,7 +29,7 @@ class BotoCWClient(CloudWatchConnection):
     '''
     Wrapper class for boto CloudWatchConnection class
     '''
-    # TODO : These should probably go in the CW API and be imported
+    # TODO(unknown) : These should probably go in the CW API and be imported
     DEFAULT_NAMESPACE = "heat/unknown"
     METRIC_UNITS = ("Seconds", "Microseconds", "Milliseconds", "Bytes",
                     "Kilobytes", "Megabytes", "Gigabytes", "Terabytes",
index 07460ff79f58303188f4b49dbc2ea39e3452e6ec..f19bbcc4a103e25985761032a50d4678de77b6db 100644 (file)
@@ -43,7 +43,7 @@ class InternetGateway(resource.Resource):
         ext_filter = {'router:external': True}
         ext_nets = client.list_networks(**ext_filter)['networks']
         if len(ext_nets) != 1:
-            # TODO sbaker if there is more than one external network
+            # TODO(sbaker) if there is more than one external network
             # add a heat configuration variable to set the ID of
             # the default one
             raise exception.Error(
index 1adde63e2f738dad80f69dd9a1549307742329b4..d1d81d0792954e3212a9c320e3b0333d17f22bbc 100644 (file)
@@ -53,7 +53,7 @@ class RouteTable(resource.Resource):
         vpc_md['all_router_ids'].append(router['id'])
         vpc.metadata = vpc_md
 
-        # TODO sbaker all_router_ids has changed, any VPCGatewayAttachment
+        # TODO(sbaker) all_router_ids has changed, any VPCGatewayAttachment
         # for this vpc needs to be notified
         self.resource_id_set(router['id'])
 
@@ -72,7 +72,7 @@ class RouteTable(resource.Resource):
         vpc_md = vpc.metadata
         vpc_md['all_router_ids'].remove(router_id)
         vpc.metadata = vpc_md
-        # TODO sbaker all_router_ids has changed, any VPCGatewayAttachment
+        # TODO(sbaker) all_router_ids has changed, any VPCGatewayAttachment
         # for this vpc needs to be notified
 
     def handle_update(self, json_snippet):
index a4e8a7c61e87f018fe3823656cab53ce793ca8b8..bbdbbc9a654ae25b10f966ed0003d869c378df46 100644 (file)
@@ -46,7 +46,7 @@ class Subnet(resource.Resource):
 
     def handle_create(self):
         client = self.quantum()
-        # TODO sbaker Verify that this CidrBlock is within the vpc CidrBlock
+        # TODO(sbaker) Verify that this CidrBlock is within the vpc CidrBlock
         network_id = self.properties.get('VpcId')
         vpc = self.stack.resource_by_refid(network_id)
         router_id = vpc.metadata['router_id']
@@ -59,7 +59,7 @@ class Subnet(resource.Resource):
         }
         subnet = client.create_subnet({'subnet': props})['subnet']
 
-        #TODO sbaker check for a non-default router for this network
+        #TODO(sbaker) check for a non-default router for this network
         # and use that instead if it exists
         client.add_interface_router(
             router_id,
@@ -78,7 +78,7 @@ class Subnet(resource.Resource):
         router_id = self.metadata['router_id']
         subnet_id = self.resource_id
 
-        #TODO sbaker check for a non-default router for this network
+        #TODO(sbaker) check for a non-default router for this network
         # and remove that instead if it exists
         try:
             client.remove_interface_router(
index 48b58326022073910d1b3cf53065dd4e15346b95..de01b485b918f883b97c7ac1207841297b0c856b 100644 (file)
@@ -97,7 +97,7 @@ class User(resource.Resource):
         return unicode(self.physical_resource_name())
 
     def FnGetAtt(self, key):
-        #TODO Implement Arn attribute
+        #TODO(asalkeld) Implement Arn attribute
         raise exception.InvalidTemplateAttribute(
             resource=self.physical_resource_name(), key=key)
 
index 8ef8eabe780dc27330897335c75876137511eabe..0a99d80dc84bbd4d66432f17344ce8da80cc7ddc 100644 (file)
@@ -434,7 +434,7 @@ class CfnStackControllerTest(HeatTestCase):
         expected = "abcdef"
         self.assertEqual(result, expected)
 
-    # TODO : test the _get_template TemplateUrl case
+    # TODO(shardy) : test the _get_template TemplateUrl case
 
     def test_create(self):
         # Format a dummy request
index 169f04e155676009d2e82d6263dfbb88a6c0e1a5..d01373d9c3e4041c8971cfb60e764bf396e19066 100644 (file)
@@ -119,7 +119,7 @@ class EIPTest(HeatTestCase):
         resource = self.create_eip(t, stack, 'IPAddress')
         association = self.create_association(t, stack, 'IPAssoc')
 
-        # TODO sbaker, figure out why this is an empty string
+        # TODO(sbaker), figure out why this is an empty string
         #self.assertEqual('', association.FnGetRefId())
 
         association.delete()
diff --git a/tox.ini b/tox.ini
index 4240ad26e98858d0fcfa2c1e22a8382a3f6e99b5..99e473e3f3b311de1d948b6f2bca84280b7e8f01 100644 (file)
--- a/tox.ini
+++ b/tox.ini
@@ -22,7 +22,7 @@ commands =
   python setup.py testr --coverage
 
 [flake8]
-ignore = H302,H303,H304,H403,H404,F403,F841,H306,H201,H101,H703,H702
+ignore = H302,H303,H304,H403,H404,F403,F841,H306,H201,H702,H703
 show-source = true
 builtins = _
 exclude=.venv,.git,.tox,dist,doc,*openstack/common*,*lib/python*,*egg,tools,build