JSON error when syncing
When i try to sync zotero, i get this error:
JSON Error: Syntax error, malformed JSON
error id: 1998691737
I didn't do anything special. It's the first time i have seen this error. What should i do?
JSON Error: Syntax error, malformed JSON
error id: 1998691737
I didn't do anything special. It's the first time i have seen this error. What should i do?
What should i do for now? Should i reinstall? Would that put the last added items at risk or something?
Thanks for your work and quick reply.
Could you go to Tools → Developer → Run JavaScript, paste in this code, press Run, and copy the output from the right-hand pane?
var req = await Zotero.HTTP.request('GET', 'https://zotero-static.s3.amazonaws.com/wp.txt');var text = req.response;var r = (num, c=true) => { text = text.repeat(num);return Zotero.HTTP.request('POST', 'https://api.zotero.org/gztest', { body: text, compressBody: c }).then(req => req.response); };return Promise.all([r(1, false), r(1), r(2), r(3)]).then(responses => responses.join('\n'));
"Error: HTTP POST https://api.zotero.org/gztest failed with status code undefined"
If not, can you provide a Debug ID for running that?
Is this a work network? Are you connecting via a proxy server?
var req = await Zotero.HTTP.request('GET', 'https://zotero-static.s3.amazonaws.com/wp.txt');var text = req.response;var r = (num, c=true) => { text = text.repeat(num);try { return Zotero.HTTP.request('POST', 'https://api.zotero.org/gztest', { body: text, compressBody: c }).then(req => req.response); } catch (e) { return "Fail " + num; } };return Promise.all([r(1, false), r(1), r(2), r(3)]).then(responses => responses.join('\n'));
The second javascript code produces this message: Error: HTTP POST https://api.zotero.org/gztest failed with status code undefined; and this debug code: D1666065682.
I'm not behind a proxy, and i have disabled the firewall.
var req = await Zotero.HTTP.request('GET', 'https://zotero-static.s3.amazonaws.com/wp.txt');var text = req.response;var r = (n, c=true) => { let body = text.substr(0, n); try { return Zotero.HTTP.request('POST', 'https://api.zotero.org/gztest', { body, compressBody: c, logBodyLength: 50 }).then(req => req.response); } catch (e) { return "Fail " + num; } };let responses = []; for (let p of [[50000, false], [50000], [100000], [300000], [500000], [1000000], [2000000]]) { responses.push(await r.apply({}, p)); } return responses.join('\n');
var req = await Zotero.HTTP.request('GET', 'https://zotero-static.s3.amazonaws.com/wp.txt');var text = req.response;var r = async function (n, c=true) { let body = text.substr(0, n); try { return await Zotero.HTTP.request('POST', 'https://api.zotero.org/gztest', { body, compressBody: c, logBodyLength: 50 }).then(req => req.response); } catch (e) { return "Fail " + num; } };let responses = []; for (let p of [[50000, false], [50000], [100000], [300000], [500000], [1000000], [2000000]]) { responses.push(await r.apply({}, p)); } return responses.join('\n');
No Debug ID needed for this one.
Is this a very slow/unreliable internet connection, at least in terms of upload bandwidth? Your original report was for a fairly large upload, but from the above, a small 50 KB upload is taking 100 seconds before failing.
Have you successfully synced before from this network? Is this a laptop? If so, have you tried from another network?
Thanks again for all your work and impressive quickness. Best regards.