code: def replace_surrogate_decode(mybytes):
      
      decoded = []
      for ch in mybytes:
          # We may be parsing newbytes (in which case ch is an int) or a native
          # str on Py2
          if isinstance(ch, int):
              code = ch
          else:
              code = ord(ch)
          if 0x80 <= code <= 0xFF:
              decoded.append(_unichr(0xDC00 + code))
          elif code <= 0x7F:
              decoded.append(_unichr(code))
          else:
              # # It may be a bad byte
              # # Try swallowing it.
              # continue
              # print("RAISE!")
              raise NotASurrogateError
      return str().join(decoded)
docs: Returns a (unicode) string