diff options
author | Yoshihiro Kaneko <ykaneko0929@gmail.com> | 2014-05-13 19:33:48 +0900 |
---|---|---|
committer | FUJITA Tomonori <fujita.tomonori@lab.ntt.co.jp> | 2014-05-14 13:19:16 +0900 |
commit | 16839dfc68c9e75a87655b972a5df2c722070f6d (patch) | |
tree | abff90a9ec75e22fb9c7e6a55025ce4db4fb135d | |
parent | 89a428b10bf2e954f136e4ab603f73aa1f7e9b69 (diff) |
controller: fix pep8
Signed-off-by: Yoshihiro Kaneko <ykaneko0929@gmail.com>
Signed-off-by: FUJITA Tomonori <fujita.tomonori@lab.ntt.co.jp>
-rw-r--r-- | ryu/controller/controller.py | 6 | ||||
-rw-r--r-- | ryu/controller/dpset.py | 4 |
2 files changed, 5 insertions, 5 deletions
diff --git a/ryu/controller/controller.py b/ryu/controller/controller.py index 48ab83cc..a18d6668 100644 --- a/ryu/controller/controller.py +++ b/ryu/controller/controller.py @@ -58,7 +58,7 @@ class OpenFlowController(object): # entry point def __call__(self): - #LOG.debug('call') + # LOG.debug('call') self.server_loop() def server_loop(self): @@ -84,7 +84,7 @@ class OpenFlowController(object): CONF.ofp_tcp_listen_port), datapath_connection_factory) - #LOG.debug('loop') + # LOG.debug('loop') server.serve_forever() @@ -147,7 +147,7 @@ class Datapath(ofproto_protocol.ProtocolDesc): msg = ofproto_parser.msg(self, version, msg_type, msg_len, xid, buf) - #LOG.debug('queue msg %s cls %s', msg, msg.__class__) + # LOG.debug('queue msg %s cls %s', msg, msg.__class__) if msg: ev = ofp_event.ofp_msg_to_ev(msg) self.ofp_brick.send_event_to_observers(ev, self.state) diff --git a/ryu/controller/dpset.py b/ryu/controller/dpset.py index b74e2ec4..399bed93 100644 --- a/ryu/controller/dpset.py +++ b/ryu/controller/dpset.py @@ -112,7 +112,7 @@ class DPSet(app_manager.RyuApp): self.logger.debug('DPSET: Forgetting datapath %s', self.dps[dp.id]) self.logger.debug('DPSET: New datapath %s', dp) self.dps[dp.id] = dp - if not dp.id in self.port_state: + if dp.id not in self.port_state: self.port_state[dp.id] = PortState() ev = EventDP(dp, True) for port in dp.ports.values(): @@ -122,7 +122,7 @@ class DPSet(app_manager.RyuApp): def _unregister(self, dp): # see the comment in _register(). - if not dp in self.dps.values(): + if dp not in self.dps.values(): return LOG.debug('DPSET: unregister datapath %s', dp) assert self.dps[dp.id] == dp |