Add E265 to the pep8 check list

E265 block comment should start with '#'

Change-Id: Ia1712504559ab8d43769d07724937ce65100dc07
Partial-Bug: #1663864
This commit is contained in:
Hong Hui Xiao 2017-02-12 08:59:00 +08:00
parent 9ebc948a37
commit e6db08a184
10 changed files with 17 additions and 18 deletions

View File

@ -101,7 +101,7 @@ CT_ZONE_REG = 0x1d402
MIN_PORT = 1
MAX_PORT = 65535
#TODO(oanson) Remove once Aging app is fully updated to use cookie framework
# TODO(oanson) Remove once Aging app is fully updated to use cookie framework
GLOBAL_AGING_COOKIE_MASK = 0x1
GLOBAL_INIT_AGING_COOKIE = 0x1

View File

@ -290,7 +290,7 @@ class DHCPApp(df_base_app.DFlowApp):
if tunnel_type == n_p_const.TYPE_VXLAN:
return mtu - n_p_const.VXLAN_ENCAP_OVERHEAD if mtu else 0
elif tunnel_type == n_p_const.TYPE_GENEVE:
#TODO(gampel) use max_header_size param when we move to ML2
# TODO(gampel) use max_header_size param when we move to ML2
return mtu - n_p_const.GENEVE_ENCAP_MIN_OVERHEAD if mtu else 0
elif tunnel_type == n_p_const.TYPE_GRE:
return mtu - n_p_const.GRE_ENCAP_OVERHEAD if mtu else 0

View File

@ -274,7 +274,7 @@ class L3App(df_base_app.DFlowApp):
priority=const.PRIORITY_HIGH,
match=match)
#add dst_mac=gw_mac l2 goto l3 flow
# add dst_mac=gw_mac l2 goto l3 flow
router_unique_key = router.get_unique_key()
match = parser.OFPMatch()
match.set_metadata(local_network_id)

View File

@ -193,7 +193,7 @@ class L3ProactiveApp(df_base_app.DFlowApp):
else:
self._add_concrete_router_interface(router, lport)
#add dst_mac=gw_mac l2 goto l3 flow
# add dst_mac=gw_mac l2 goto l3 flow
match = parser.OFPMatch()
match.set_metadata(local_network_id)
match.set_dl_dst(haddr_to_bin(mac))

View File

@ -551,7 +551,7 @@ class NbApi(object):
id, 'create', lrouter_json, topic)
def update_lrouter(self, id, topic, **columns):
#TODO(gampel) move the router ports to a separate table
# TODO(gampel) move the router ports to a separate table
lrouter_json = self.driver.get_key(db_models.LogicalRouter.table_name,
id, topic)
lrouter = jsonutils.loads(lrouter_json)

View File

@ -187,14 +187,14 @@ class ZookeeperDbDriver(db_api.DbApi):
return self._allocate_unique_key(table)
def register_notification_callback(self, callback):
#NOTE(nick-ma-z): The pub-sub mechanism is not initially supported.
# The watcher function of Zookeeper only supports
# one-time trigger. You have to continuously register
# watchers for each children. Moreover, the delay
# between trigger and registration causes lose of
# events. The DataWatch of Kazoo is also not that
# stable and easy to use. Thanks to build-in pub-sub
# of dragonflow, we don't need to work hard on zk side.
# NOTE(nick-ma-z): The pub-sub mechanism is not initially supported.
# The watcher function of Zookeeper only supports
# one-time trigger. You have to continuously register
# watchers for each children. Moreover, the delay
# between trigger and registration causes lose of
# events. The DataWatch of Kazoo is also not that
# stable and easy to use. Thanks to build-in pub-sub
# of dragonflow, we don't need to work hard on zk side
return
def register_topic_for_notification(self, topic):

View File

@ -197,7 +197,7 @@ class ZMQSubscriberAgent(ZMQSubscriberAgentBase):
context = zmq.Context()
socket = context.socket(zmq.SUB)
for uri in self.uri_list:
#TODO(gampel) handle exp zmq.EINVAL,zmq.EPROTONOSUPPORT
# TODO(gampel) handle exp zmq.EINVAL,zmq.EPROTONOSUPPORT
LOG.debug("about to connect to network publisher at %s", uri)
socket.connect(uri)
for topic in self.topic_list:

View File

@ -151,7 +151,7 @@ def main():
cfg.CONF.register_opts(df_db_test_opts, 'df_db_test')
common_config.init(sys.argv[2:])
# To enable logging, uncomment the following line:
#common_config.setup_logging()
# common_config.setup_logging()
nb_driver_class = importutils.import_class(cfg.CONF.df.nb_db_class)
is_server = False
if sys.argv[1] == 'server':

View File

@ -51,7 +51,7 @@ class TestRedisDB(tests_base.BaseTestCase):
self.RedisDbDriver.redis_mgt = redis_mgt
redis_mgt.get_ip_by_key.return_value = '0.0.0.0:1000'
#test get_key
# test get_key
result = self.RedisDbDriver.get_key('table', 'key')
self.assertEqual('value', result)
redis_mgt.get_ip_by_key.assert_called_with('a')

View File

@ -50,11 +50,10 @@ commands = sphinx-build -W -b html doc/source doc/build/html
# E126 continuation line over-indented for hanging indent
# E128 continuation line under-indented for visual indent
# E129 visually indented line with same indent as next logical line
# E265 block comment should start with #
# H404 multi line docstring should start with a summary
# H405 multi line docstring summary not separated with an empty line
# N530 Direct neutron imports not allowed
ignore = E126,E128,E129,E265,H404,H405,N530
ignore = E126,E128,E129,H404,H405,N530
# H904: Delay string interpolations at logging calls
enable-extensions=H904
show-source = true