JSON parse error: Unexpected character (‘ ‘ (code 160))-PostMan里面Json参数编码不一致解决方法

拼搏现实的明天。 2024-03-17 21:39 169阅读 0赞

PostMan里面Json参数编码不一致解决方法

一:报错日志为JSON parse error: Unexpected character (’ ’ (code 160))

注意看==={Unexpected character (’ ’ (code 160))}

  1. 2023-07-18 16:35:57.624 ERROR 29624 --- [ XNIO-1 task-1] o.s.c.log.error.RestExceptionTranslator : 消息不能读取:JSON parse error: Unexpected character (' ' (code 160)): was expecting double-quote to start field name; nested exception is com.fasterxml.jackson.core.JsonParseException: Unexpected character (' ' (code 160)): was expecting double-quote to start field name
  2. at [Source: (PushbackInputStream); line: 1, column: 4]
  3. 2023-07-18 16:38:07.334 ERROR 29624 --- [ XNIO-1 task-1] o.s.c.log.error.RestExceptionTranslator : 消息不能读取:JSON parse error: Invalid UTF-8 start byte 0xa0; nested exception is com.fasterxml.jackson.core.JsonParseException: Invalid UTF-8 start byte 0xa0
  4. at [Source: (PushbackInputStream); line: 1, column: 23]
  5. 2023-07-18 16:40:06.600 ERROR 29624 --- [ XNIO-1 task-1] o.s.c.log.error.RestExceptionTranslator : 消息不能读取:JSON parse error: Unexpected character (' ' (code 160)): was expecting double-quote to start field name; nested exception is com.fasterxml.jackson.core.JsonParseException: Unexpected character (' ' (code 160)): was expecting double-quote to start field name
  6. at [Source: (PushbackInputStream); line: 1, column: 46]

二:解决方法-如下图-点击右侧Beautify按钮将Json参数编码格式化

在这里插入图片描述

三:再次请求-解决此问题

发表评论

表情:
评论列表 (有 0 条评论,169人围观)

还没有评论,来说两句吧...

相关阅读