#JSON.parse error

1 messages · Page 1 of 1 (latest)

lucid falcon
#

I get this from a server I tried to run with bun instead of node:

252 |       if (results.accu.code == 200)
253 | 
254 |         data.accu = JSON.parse(results.accu.data);
                       ^
SyntaxError: JSON Parse error: Unrecognized token 'ߋ'

Any idea what can be the reason? Is it a bun bug? It always worked fine with nodejs
I consolelogged the contents of body, and it looks like valid JSON, no weird characters.
I believe it could be related to the request api, actually, which is where body comes from:
const request = require('request');

vocal wraith
#

@sage magnet this channel is for help, just help if you know how

undone hatch
#

I'd need a reproduction to debug this @lucid falcon