def update_from_tuple(self, the_tuple):
if not the_tuple.rowcount:<EOL><INDENT>raise Queue.ZeroTupleException("<STR_LIT>")<EOL><DEDENT>row = the_tuple[<NUM_LIT:0>]<EOL>if self.task_id != row[<NUM_LIT:0>]:<EOL><INDENT>raise Queue.BadTupleException("<STR_LIT>")<EOL><DEDENT>self.state = row[<NUM_LIT:1>]<EOL>self.data = row[<NUM_LIT:2>]<EOL>
Update task from tuple.