def update_result(result):
try:<EOL><INDENT>result_id = result.id<EOL>result = _forbidden_attributes(result)<EOL>res = _pybossa_req('<STR_LIT>', '<STR_LIT:result>', result_id, payload=result.data)<EOL>if res.get('<STR_LIT:id>'):<EOL><INDENT>return Result(res)<EOL><DEDENT>else:<EOL><INDENT>return res<EOL><DEDENT><DEDENT>except:  <EOL><INDENT>raise<EOL><DEDENT>
Update a result for a given result ID.

    :param result: PYBOSSA result