naptha / tesseract.js

Pure Javascript OCR for more than 100 Languages 📖🎉🖥
http://tesseract.projectnaptha.com/
Apache License 2.0
35.31k stars 2.23k forks source link

Network error while fetching #858

Closed daniellwdb closed 11 months ago

daniellwdb commented 11 months ago

Tesseract.js version (version number for npm/GitHub release, or specific commit for repo) "tesseract.js": "^5.0.3"

Describe the bug Call to createWorker results in:

Error: Error: Network error while fetching https://cdn.jsdelivr.net/npm/@tesseract.js-data/en/4.0.0/en.traineddata.gz. Response code: 404

To Reproduce Steps to reproduce the behavior: npm i tesseract.js@latest

import { createWorker } from "tesseract.js";

createWorker("en", 4)

Expected behavior Language data should be downloaded.

Device Version:

Additional context Manually adding the eng.traineddata file to my project root (like how it was downloaded in the past) does not work either

Balearica commented 11 months ago

en is not a valid language code. Presumably you mean eng for English. A full list of language codes can be found here.

daniellwdb commented 11 months ago

Thanks!