<SYSTEM_TASK:>
Solve the following problem using Python, implementing the functions described below, one line at a time
<END_TASK>
<USER_TASK:>
Description:
 def log_to_stream(level=None, fmt=None, datefmt=None):
 """ Send log messages to the console. Parameters level : int, optional An optional logging level that will apply only to this stream handler. fmt : str, optional An optional format string that will be used for the log messages. datefmt : str, optional An optional format string for formatting dates in the log messages. """

    _add_log_handler(
        logging.StreamHandler(), fmt=fmt, datefmt=datefmt, propagate=False)