Spawning subprocesses is not allowed on Deno Deploy

I’m trying to build a OCR service, with URL: https://starlit-travesseiro-cabceb.netlify.app/ocr?url=https://tesseract.projectnaptha.com/img/eng_bw.png

I got error

Spawning subprocesses is not allowed on Deno Deploy.

Can anyone help?

I think the error is saying what’s wrong.

Also, Edge Functions run for 50ms - how do you plan to perform OCR in that time?

1 Like

I see, basically, I’m looking for some alternative solution.

I don’t think Netlify has anything to offer that could allow you to perform OCR. You could try using Background Functions, as they can run for 15 mins, which should be enough time to perform some level of OCR, but you’d have to store the result externally, as Background Functions don’t allow you to return data to the client.