#NEWLINE# @ imm_action ( 'patch' , '__dict__' , imm_level = 'supreme' , prep = ':' , obj_target_class = 'args' ) #NEWLINE# def patch( target , verb , args , command , **_ ) : #NEWLINE# #INDENT# try : #NEWLINE# #INDENT# split_ix = args . index ( ':' ) #NEWLINE# prop = args [ ( split_ix + 1 ) ] #NEWLINE# new_value = find_extra ( verb , ( split_ix + 2 ) , command ) #NEWLINE# #UNINDENT# except ( ValueError , IndexError ) : #NEWLINE# #INDENT# return "Syntax -- 'patch [target] [:] [prop_name] [new_value]'" #NEWLINE# #UNINDENT# if ( not new_value ) : #NEWLINE# #INDENT# return 'New value required' #NEWLINE# #UNINDENT# if ( new_value == 'None' ) : #NEWLINE# #INDENT# new_value = None #NEWLINE# #UNINDENT# patch_object ( target , args , new_value ) #NEWLINE# return 'Object successfully patched'