<SYSTEM_TASK:>
Solve the following problem using Python, implementing the functions described below, one line at a time
<END_TASK>
<USER_TASK:>
Description:
 def run_job(key, node):
 """Run a job. This applies the function node, and returns a |ResultMessage| when complete. If an exception is raised in the job, the |ResultMessage| will have ``'error'`` status. .. |run_job| replace:: :py:func:`run_job`"""

    try:
        result = node.apply()
        return ResultMessage(key, 'done', result, None)

    except Exception as exc:
        return ResultMessage(key, 'error', None, exc)