[squeak-dev] Re: UTF8 in JSON (was: Re: [ANN] WebClient and
WebServer 1.0 for Squeak)
radoslav hodnicak
rh at 4096.sk
Mon May 10 21:39:40 UTC 2010
Which JSON package/version are you using? I fixed a bug in the one
distributed with SCouchDB few weeks ago, where it didn't encode utf8
characters properly - the correct escaped form is \uNNNN - always padded
to 4 Ns. that's why you get that warning, yours is only 2-3
rado
On Mon, 10 May 2010, Hannes Hirzel wrote:
> The test case made simpler
>
> WebClient httpPut: host, '/notes/test7' content:
> '{"content":"\uC3\uA4s"}' type: 'text/plain'.
>
> gives back as answer: '{"error":"bad_request","reason":"invalid UTF-8 JSON"}
> '
>
> whereas
>
> WebClient httpPut: host, '/notes/test8' content: '{"content":"abc"}'
> type: 'text/plain'.
>
> gives back
> '{"ok":true,"id":"test8","rev":"1-f40e52919735ae6775af3d388361b3da"}
> '
>
> --Hannes
More information about the Squeak-dev
mailing list
|