def _stderr_supports_color():
    color = False
    if curses and sys.stderr.isatty():
        try:
            curses.setupterm()
            if curses.tigetnum("colors") > 0:
                color = True
        except Exception:
            pass
    return color
dataset/ETHPy150Open D-L/SimpleBookMarks/src/tornado/log.py/_stderr_supports_color/original