[libprotobuf ERROR google/protobuf/wire_format.cc:1053] String field contains invalid UTF-8 data when serializing a protocol buffer. Use the 'bytes' type if you intend to send raw bytes. 原因是中间,用char[]把它截断了,造成utf8字符不完整…
var response = httpClient.SendAsync(requestMessage).Result; content = response.Content.ReadAsStringAsync().Result; 正常是可以获取数据的,不过这次抛了异常,异常信息如下 The character set provided in ContentType is invalid. Cannot read content as string using an invalid charact…
models.py 文件 # coding:utf8 from django.db import models class Book(models.Model): name = models.CharField(max_length=255) title = models.CharField(max_length=255) price = models.IntegerField() ... class Category(models.Model)…