[ckan-dev] API: json-parser broken; Access denied
Pascal Christoph
christoph at hbz-nrw.de
Mon Sep 26 10:11:00 UTC 2011
Am 20.09.2011 21:08 schrieb Florian Marienfeld:
> Have you tried adding this header to your request:
>
> Content-Type: application/json;charset=utf-8
uhm, well, yes! Thanx, that does it :)
oo
> see http://trac.ckan.org/ticket/1312
>
> That did the trick for us.
>
> On 20.09.11 17:30, Pascal Christoph wrote:
>> Dear all,
>>
>> trying to upload json (here the problematic fragment):
>>
>> {
>> "url": "http://lobid.org/resource/data/HT002948556?output=xml"
>> },
>>
>> results in:
>> "Bad request - JSON Error: Error parsing JSON data. Error:
>> ValueError('Unterminated string starting at: line 1 column 828 (char
>> 828)',) JSON (Decoded and re-encoded): '{ \"extras\": "
>> [...] "url\": \"http://lobid.org/resource/data/HT002948556?output'"
>>
>> When I try instead
>> {
>> "url": "http://lobid.org/resource/data/HT002948556"
>> },
>>
>> there is no Error. As I understand the former *is* valid JSON, so there
>> seems to be an error within your JSON parser.
>>
>> -o
>>
>> _______________________________________________
>> ckan-dev mailing list
>> ckan-dev at lists.okfn.org
>> http://lists.okfn.org/mailman/listinfo/ckan-dev
>
>
> _______________________________________________
> ckan-dev mailing list
> ckan-dev at lists.okfn.org
> http://lists.okfn.org/mailman/listinfo/ckan-dev
More information about the ckan-dev
mailing list