def wsgi_to_bytes(data):
 if isinstance(data, bytes):
  return data
 return data.encode('latin1')

def wsgi_to_bytes ( data ) : if isinstance ( data , bytes ) : return data return data . encode ( 'latin1' )
coerce wsgi unicode represented bytes to real ones .