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
Properly catch exception so that test can run to end #27752
Conversation
Met WebDriverException and it is not properly catched, and cause an Assertion error in restart_runner, cause the whole test abort early Bug: 27751
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
For some additional background, this happens when a new test starts and webdriver attempts to activate the newly-created window but the browser crashes in the middle of the navigation.
The effect is that the uncaught exception goes all the way out to the runner manager and aborts the test loop.
This kind of browser issue should be handled gracefully in the runner.
try: | ||
if test.environment != self.last_environment: |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I wonder if this should be in a separate try/except block before this one, and perhaps results in an "INTERNAL-ERROR" or something? Maybe @jgraham can comment.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Luke, if this is due to an issue at browser side, then "ERROR" is more appropriate? I tried and did not reproduce this on clank. What does "INTERNAL-ERROR" mean? thanks!
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think result_from_exception
will convert this into INTERNAL-ERROR
and I think that's the correct result for this case (since it's an error not assoicated with the specific test code).
try: | ||
if test.environment != self.last_environment: |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think result_from_exception
will convert this into INTERNAL-ERROR
and I think that's the correct result for this case (since it's an error not assoicated with the specific test code).
Met WebDriverException and it is not properly catched,
and cause an Assertion error in restart_runner, cause
the whole test abort early
Bug: 27751