code: def color(self, log_colors, level_name):
          
          if not self.stream.isatty():
              log_colors = {}
          return ColoredFormatter.color(self, log_colors, level_name)
docs: Only returns colors if STDOUT is a TTY.