Skip to content

transfer-encoding chunked not handled for application/json #1768

@DaveStein

Description

@DaveStein

Summary

I am receiving JSON via chunked encoding. response.data comes back as a string. It is not properly parsed as the headers instruct. I would expect to get a JSON object back for res.data.

Response Headers:

Content-Type: application/json
Transfer-Encoding: chunked, chunked

Response Data:

23\r\n
{"rejected":0,"inserted/updated":1}\r\n
0\r\n
\r\n
\r\n

Theoretically this response would also be valid:

18\r\n
{"rejected":0,"inserted/update\r\n
5\r\n
d":1}\r\n
0\r\n
\r\n
\r\n

Context

  • axios version: e.g.: 0.18.0
  • Environment: e.g.: node v8.10.0, High Sierra

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions