-
Notifications
You must be signed in to change notification settings - Fork 11
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
new locale assertions in Tesseract are incompatible with Click #23
Comments
So the tests work because they use the |
Oh you fixed it already. Self-fixing issues are the best issues 👍 |
No, the tests (presumably) still work, because they use an older Tesseract version without the assertion in place. True, we should add a CLI test (as in core/test/test_cli.py)... |
They did fail before but we set the locale to https://github.com/OCR-D/ocrd_tesserocr/blob/master/.travis.yml#L32 |
Oh, I see. I was distracted by my (non-container) test results. |
Ever since Tesseract 4 had to introduce an assertion that localization be plain POSIX (
C
) to ensure certain legacy assumptions in its code are always met, we have to override the current locale before initializingtesserocr
API, too. This cannot be done by the user before calling anyocrd_tesserocr
CLI, because we depend on the Click library, which itself is incompatible (in Python 3) with that locale (it requires at leastC.UTF-8
). So we have a deadlock.We could perhaps reset the locale after
click
and beforetesserocr
though.The text was updated successfully, but these errors were encountered: