doit: Remove tessdata dir from targets

Remove the tesseract data dir from the doit targets, else we encounter
the following error:

  Traceback (most recent call last):
    [...]
    File "[...]/Library/Caches/pypoetry/virtualenvs/dangerzone-52Yr5wv_-py3.11/lib/python3.11/site-packages/doit/dependency.py", line 39, in get_file_md5
      with open(path, 'rb') as file_data:
           ^^^^^^^^^^^^^^^^
  IsADirectoryError: [Errno 21] Is a directory: 'share/tessdata'
This commit is contained in:
Alex Pyrgiotis 2025-04-02 11:46:18 +03:00
parent 092eec55d1
commit e0b10c5e40
No known key found for this signature in database
GPG key ID: B6C15EBA0357C9AA

View file

@ -43,7 +43,6 @@ def list_language_data():
tessdata_dir = Path("share") / "tessdata"
langs = json.loads(open(tessdata_dir.parent / "ocr-languages.json").read()).values()
targets = [tessdata_dir / f"{lang}.traineddata" for lang in langs]
targets.append(tessdata_dir)
return targets