<SYSTEM_TASK:>
Solve the following problem using Python, implementing the functions described below, one line at a time
<END_TASK>
<USER_TASK:>
Description:
 def worker(compute, task_queue, result_queue, log_queue, complete, *context):
 """A worker process, run by ``multiprocessing.Process``."""

        try:
            MapReduce._forked = True
            log.debug('Worker process starting...')

            configure_worker_logging(log_queue)

            for obj in iter(task_queue.get, POISON_PILL):
                if complete.is_set():
                    log.debug('Worker received signal - exiting early')
                    break

                log.debug('Worker got %s', obj)
                result_queue.put(compute(obj, *context))
                log.debug('Worker finished %s', obj)

            result_queue.put(POISON_PILL)
            log.debug('Worker process exiting')

        except Exception as e:  # pylint: disable=broad-except
            result_queue.put(ExceptionWrapper(e))