Skip to content

http -v should show escaped Unicode as-is #1474

@wataash

Description

@wataash

In the two commands below, both shows the same JSON.

$ http -v httpbin.org/post a:='"あ"'
...
{
    "a": ""
}
...

$ echo '{"a": "あ"}' | http -v httpbin.org/post
...
{
    "a": ""
}
...

But actually they send different data:

image
image

In the first command, I expect it to show \u3042, but it seems parse the escaped Unicode and show the parsed letter .

i.e. it should output:

$ http -v httpbin.org/post a:='"あ"'
...
{
    "a": "\u3042"
}
...

$ echo '{"a": "あ"}' | http -v httpbin.org/post
...
{
    "a": ""
}
...

See also #814.

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't workingnewNeeds triage. Comments are welcome!

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions