<SYSTEM_TASK:>
Solve the following problem using Python, implementing the functions described below, one line at a time
<END_TASK>
<USER_TASK:>
Description:
 def standard_stream_redirector(stream):
 """ Temporarily redirect stdout and stderr to another stream. This can be useful for capturing messages for easier inspection, or for rerouting and essentially ignoring them, with the destination as something like an opened os.devnull. :param FileIO[str] stream: temporary proxy for standard streams """

    import sys
    genuine_stdout, genuine_stderr = sys.stdout, sys.stderr
    sys.stdout, sys.stderr = stream, stream
    try:
        yield
    finally:
        sys.stdout, sys.stderr = genuine_stdout, genuine_stderr