code: def write(self, msg, style_func=None, ending=None, stream=None):
          
          if stream is None:
              stream = self.stdout
          if OutputWrapper is None:
              ending = "\n" if ending is None else ending
              msg += ending
              stream.write(msg)
          else:
              stream.write(msg, style_func=style_func, ending=ending)
docs: wrapper around self.stdout/stderr to ensure Django 1.4 compatibility