don't hang if exiftool unexpectedly exits#81
Open
diekhans wants to merge 1 commit intosylikc:masterfrom
Open
Conversation
Owner
|
Thanks for the issue report and PR. I'm going to have to see if I can write a test case to test this on both windows and Linux. Does this occur when running a (probably easier to test on a long process) and then killing exiftool process while results are coming back? I'll see if I can run it through a few process dying tests. |
Author
|
The hang happened when I sent something to exiftool that caused
it throw an error. Unfortunately, I can't make that happen any
more.
This seems like a very hard thing to write a test cases for.
Timing based test cases are brittle. I just tried killing
the exiftool process while it was waiting between request
and didn't get it to hang.
Personally, I would make sure it doesn't break the non-error
cases (it passed all the test) and then do a careful code
review. Sometimes, it just isn't worth the time to write a hard
test case for rare error.
Kevin M ***@***.***> writes:
… Thanks for the issue report and PR. I'm going to have to see if I can write a test case to test this on both windows and Linux.
Does this occur when running a (probably easier to test on a long process) and then killing exiftool process while results are coming back?
I'll see if I can run it through a few process dying tests.
--
Reply to this email directly or view it on GitHub:
#81 (comment)
You are receiving this because you authored the thread.
Message ID: ***@***.***>
|
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
The select loop from exiftool does not check for EOF, causing some expect failure to cause pyexiftool to hang.
This PR doesn't address the Window case, as I can't test it. However, I think it is near identical.