pep8: fix E128 continuation line under-indented errors

I wasn't sure this was worth fixing at first, but it does look more readable
now.
This commit is contained in:
Brandon Heller
2012-11-13 16:59:10 -08:00
parent c0095746af
commit edf6003217
15 changed files with 118 additions and 116 deletions
+5 -2
View File
@@ -68,8 +68,11 @@ LINKS = { 'default': Link,
TESTS = [ 'cli', 'build', 'pingall', 'pingpair', 'iperf', 'all', 'iperfudp', TESTS = [ 'cli', 'build', 'pingall', 'pingpair', 'iperf', 'all', 'iperfudp',
'none' ] 'none' ]
ALTSPELLING = { 'pingall': 'pingAll', 'pingpair': 'pingPair', ALTSPELLING = { 'pingall': 'pingAll',
'iperfudp': 'iperfUdp', 'iperfUDP': 'iperfUdp', 'prefixlen': 'prefixLen' } 'pingpair': 'pingPair',
'iperfudp': 'iperfUdp',
'iperfUDP': 'iperfUdp',
'prefixlen': 'prefixLen' }
def addDictOption( opts, choicesDict, default, name, helpStr=None ): def addDictOption( opts, choicesDict, default, name, helpStr=None ):
+2 -5
View File
@@ -169,11 +169,8 @@ class Graph( Frame ):
"Graph that we can add bars to over time." "Graph that we can add bars to over time."
def __init__( self, parent=None, def __init__( self, parent=None, bg = 'white', gheight=200, gwidth=500,
bg = 'white', barwidth=10, ymax=3.5,):
gheight=200, gwidth=500,
barwidth=10,
ymax=3.5,):
Frame.__init__( self, parent ) Frame.__init__( self, parent )
+2 -2
View File
@@ -322,8 +322,8 @@ class MiniEdit( Frame ):
self.nodeCount += 1 self.nodeCount += 1
name = self.nodePrefixes[ node ] + str( self.nodeCount ) name = self.nodePrefixes[ node ] + str( self.nodeCount )
icon = self.nodeIcon( node, name ) icon = self.nodeIcon( node, name )
item = self.canvas.create_window( x, y, anchor='c', item = self.canvas.create_window( x, y, anchor='c', window=icon,
window=icon, tags=node ) tags=node )
self.widgetToItem[ icon ] = item self.widgetToItem[ icon ] = item
self.itemToWidget[ item ] = icon self.itemToWidget[ item ] = icon
self.selectItem( item ) self.selectItem( item )
+2 -1
View File
@@ -283,7 +283,8 @@ class TCIntf( Intf ):
# Bandwidth limits via various methods # Bandwidth limits via various methods
bwcmds, parent = self.bwCmds( bw=bw, speedup=speedup, bwcmds, parent = self.bwCmds( bw=bw, speedup=speedup,
use_hfsc=use_hfsc, use_tbf=use_tbf, use_hfsc=use_hfsc, use_tbf=use_tbf,
latency_ms=latency_ms, enable_ecn=enable_ecn, latency_ms=latency_ms,
enable_ecn=enable_ecn,
enable_red=enable_red ) enable_red=enable_red )
cmds += bwcmds cmds += bwcmds
+5 -4
View File
@@ -789,7 +789,8 @@ class UserSwitch( Switch ):
name: name for the switch""" name: name for the switch"""
Switch.__init__( self, name, **kwargs ) Switch.__init__( self, name, **kwargs )
pathCheck( 'ofdatapath', 'ofprotocol', pathCheck( 'ofdatapath', 'ofprotocol',
moduleName='the OpenFlow reference user switch (openflow.org)' ) moduleName='the OpenFlow reference user switch' +
'(openflow.org)' )
if self.listenPort: if self.listenPort:
self.opts += ' --listen=ptcp:%i ' % self.listenPort self.opts += ' --listen=ptcp:%i ' % self.listenPort
@@ -1053,7 +1054,8 @@ class NOX( Controller ):
command=noxCoreDir + '/nox_core', command=noxCoreDir + '/nox_core',
cargs='--libdir=/usr/local/lib -v -i ptcp:%s ' + cargs='--libdir=/usr/local/lib -v -i ptcp:%s ' +
' '.join( noxArgs ), ' '.join( noxArgs ),
cdir=noxCoreDir, **kwargs ) cdir=noxCoreDir,
**kwargs )
class RemoteController( Controller ): class RemoteController( Controller ):
@@ -1066,8 +1068,7 @@ class RemoteController( Controller ):
ip: the IP address where the remote controller is ip: the IP address where the remote controller is
listening listening
port: the port where the remote controller is listening""" port: the port where the remote controller is listening"""
Controller.__init__( self, name, ip=ip, port=port, Controller.__init__( self, name, ip=ip, port=port, **kwargs )
**kwargs )
def start( self ): def start( self ):
"Overridden to do nothing." "Overridden to do nothing."