I have a VPS on Digital Ocean where I'm running typebot-viewer, and randomly as the chat doesn't start.
The viewer logs in docker:
Something went wrong SyntaxError: Unexpected token 'I', "Internal S"... is not valid JSON
at JSON.parse (<anonymous>)
... 8 lines matching cause stack trace ...
at async E (/app/apps/viewer/.next/server/pages/api/[...trpc].js:222:3958) {
code: 'INTERNAL_SERVER_ERROR',
name: 'TRPCError',
[cause]: SyntaxError: Unexpected token 'I', "Internal S"... is not valid JSON
at JSON.parse (<anonymous>)
at parseJSONFromBytes (node:internal/deps/undici/undici:4306:19)
at successSteps (node:internal/deps/undici/undici:4288:27)
at fullyReadBody (node:internal/deps/undici/undici:2724:9)
at process.processTicksAndRejections (node:internal/process/task_queues:95:5)
at async consumeBody (node:internal/deps/undici/undici:4297:7)
at async m (/app/apps/viewer/.next/server/chunks/595.js:1:2990)
at async E (/app/apps/viewer/.next/server/chunks/595.js:1:1184)
at async /app/apps/viewer/.next/server/pages/api/[...trpc].js:222:7333
at async E (/app/apps/viewer/.next/server/pages/api/[...trpc].js:222:3958)
}
Firstly, this situation happened more frequently at Vercel, so I thought that was the problem.
I switched to Digital Ocean thinking it might be something related to lambda, so I hired a VPS.
Then I thought it could be the traffic, but few people access it per day, my Digital Ocean machine doesn't reach close to 80% usage of any of the resources.
My database is on RDS (AWS) and working normally.
For some reason, it happens a lot when I open the site in an anonymous tab. (I don't know what could influence it)
Sending the request to start the chat via insomnia, whenever more than 10 seconds passes, the error returns:
Sending the same thing a few seconds later returns successfully:
I have a VPS on Digital Ocean where I'm running typebot-viewer, and randomly as the chat doesn't start.
The viewer logs in docker:
Firstly, this situation happened more frequently at Vercel, so I thought that was the problem. I switched to Digital Ocean thinking it might be something related to lambda, so I hired a VPS.
Then I thought it could be the traffic, but few people access it per day, my Digital Ocean machine doesn't reach close to 80% usage of any of the resources.
My database is on RDS (AWS) and working normally.
For some reason, it happens a lot when I open the site in an anonymous tab. (I don't know what could influence it)
Sending the request to start the chat via insomnia, whenever more than 10 seconds passes, the error returns:
Sending the same thing a few seconds later returns successfully:
I have no idea what it could be :/