#NEWLINE# def act( self ) : #NEWLINE# #INDENT# activeEngines = filter ( ( lambda engine : engine . is_active ( ) ) , admin . workers . itervalues ( ) ) #NEWLINE# def extend( x , y ) : #NEWLINE# #INDENT# x . extend ( y . users ) #NEWLINE# y . users = [ ] #NEWLINE# return x #NEWLINE# #UNINDENT# activeUsers = reduce ( extend , activeEngines , [ ] ) #NEWLINE# iterEngine = cycle ( activeEngines ) #NEWLINE# for userName in activeUsers : #NEWLINE# #INDENT# engine = iterEngine . next ( ) #NEWLINE# user = monkapi . load_user ( userName ) #NEWLINE# user . partition = engine . partition #NEWLINE# user . save ( ) #NEWLINE# engine . add_user ( userName )