Skip to content
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

Improve error handling #117

Merged
merged 1 commit into from Oct 6, 2021
Merged

Conversation

perlpunk
Copy link
Contributor

@perlpunk perlpunk commented Oct 6, 2021

Add a trap call to make sure we always get a message on stderr in which script
and which line the error happened. We sometimes get a non-zero exit code but
don't know where the error happened.

I didn't add the trap to openqa-investigate, because practically the whole
code is wrapped in a conditional (investigate || error_count++), and
-e (and trap) is disabled by that.

Also turned several echos into echoerr as it was supposed to land in our
log, not in stdout.

Issue: https://progress.opensuse.org/issues/99519

Add a trap call to make sure we always get a message on stderr in which script
and which line the error happened. We sometimes get a non-zero exit code but
don't know where the error happened.

I didn't add the trap to openqa-investigate, because practically the whole
code is wrapped in a conditional (investigate || error_count++), and
-e (and trap) is disabled by that.

Also turned several echos into echoerr as it was supposed to land in our
log, not in stdout.

Issue: https://progress.opensuse.org/issues/99519
@okurz okurz merged commit bec0fd8 into os-autoinst:master Oct 6, 2021
@perlpunk perlpunk deleted the error-handling branch November 16, 2021 13:47
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants