react-native-mlkit-ocr icon indicating copy to clipboard operation
react-native-mlkit-ocr copied to clipboard

Error: Waiting for the text recognition module to be downloaded. Please wait

Open harishvgk opened this issue 2 years ago • 5 comments

Tried to detect text by passing Uri, its taking time around 5-7 seconds and showing this message in chrome browser console

let resultFromUri = await MlkitOcr.detectFromUri(uri);

package.json:

"@react-native-firebase/app": "^15.0.0", "@react-native-firebase/ml": "^15.0.0", "react-native-image-picker": "^4.8.4", "react-native-mlkit-ocr": "^0.2.5",

Error:

Possible Unhandled Promise Rejection (id: 0): Error: Waiting for the text recognition module to be downloaded. Please wait. Error: Waiting for the text recognition module to be downloaded. Please wait. at Object.promiseMethodWrapper [as detectFromUri] (http://localhost:3001/index.bundle?platform=android&dev=true&minify=false&app=com.rntextdetect&modulesOnly=false&runModule=true:2580:36) at detectFromUri$ (http://localhost:3001/index.bundle?platform=android&dev=true&minify=false&app=com.rntextdetect&modulesOnly=false&runModule=true:112555:58) at tryCatch (http://localhost:3001/index.bundle?platform=android&dev=true&minify=false&app=com.rntextdetect&modulesOnly=false&runModule=true:24259:19) at Generator._invoke (http://localhost:3001/index.bundle?platform=android&dev=true&minify=false&app=com.rntextdetect&modulesOnly=false&runModule=true:24239:26) at Generator.next (http://localhost:3001/index.bundle?platform=android&dev=true&minify=false&app=com.rntextdetect&modulesOnly=false&runModule=true:24290:23) at tryCatch (http://localhost:3001/index.bundle?platform=android&dev=true&minify=false&app=com.rntextdetect&modulesOnly=false&runModule=true:24259:19) at invoke (http://localhost:3001/index.bundle?platform=android&dev=true&minify=false&app=com.rntextdetect&modulesOnly=false&runModule=true:24297:22) at http://localhost:3001/index.bundle?platform=android&dev=true&minify=false&app=com.rntextdetect&modulesOnly=false&runModule=true:24321:13 at tryCallTwo (http://localhost:3001/index.bundle?platform=android&dev=true&minify=false&app=com.rntextdetect&modulesOnly=false&runModule=true:28716:7) at doResolve (http://localhost:3001/index.bundle?platform=android&dev=true&minify=false&app=com.rntextdetect&modulesOnly=false&runModule=true:28880:15)

How to resolve this?

Advance Thanks for Helping

harishvgk avatar Jun 21 '22 13:06 harishvgk

Same issue. Did you manage to resolve?

AbhinayMe avatar Jul 27 '22 03:07 AbhinayMe

Any update? We have only one user so far with this issue, unfortunately not reproducible on our side. We just see the error in sentry.

mwerder avatar Oct 14 '22 08:10 mwerder

I'm having multiple users with different devices reporting this issue (I cannot reproduce on my dev phones and tablets). Successfully reproduced using a Pixel 3a API 31 in the android studio simulator, but no luck with Apple devices (user reporting on iPad 12.9 Pro on iOs 15.X - couldn't reproduce in xCode simulator as it doesn't allow camera use..).

jmazier-j2d avatar Oct 17 '22 10:10 jmazier-j2d