-
Notifications
You must be signed in to change notification settings - Fork 9.6k
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
tesstrain.sh continues even if text2image crashed. #2005
Comments
@zdenop There are other issues with text2image and tesstrain.sh also. Many times it fails to create box file for a certain font but continues on any way and fails at the next step when it does not find the box file. |
@Shreeshrii : did you understand description above and I test I made? |
@zdenop I needed to test it out to understand it. The exit status/code is based on the last command run.
So completion status displays status of https://unix.stackexchange.com/questions/14270/get-exit-status-of-process-thats-piped-to-another The following works, using pipefail:
output:
|
@stweil Is using pipefail the best way of handling this? |
@Shreeshrii : can you try to add |
@zdenop actually setting -u in
This appears to fix the former ones at least in my short test:
|
thanks! |
see comment: #1999 (comment)
Problem seems to be that "check completion status" in
tesstrain_utils.sh
is wrong/does not work as expected. Here is short test:IMO according design logic
run_command
should exit script (becausetext2image --?
returns exit code 1) , but it continue and user see "Everything is fine. Press any key..."The text was updated successfully, but these errors were encountered: