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

Figure out design for handling errors #1

Open
istathar opened this issue Sep 23, 2022 · 0 comments
Open

Figure out design for handling errors #1

istathar opened this issue Sep 23, 2022 · 0 comments
Assignees

Comments

@istathar
Copy link
Member

Basic functionality for tracer is working!

I think what's missing, however, is a notion of what to do in the case of encountering an error. This seems to have two parts

  1. detecting an error has occurred in a child process
  2. causing a root span to be emitted anyway

Detecting errors

The first one smacks a bit of being a "long tail" problem. GitHub Actions, for example, attempt to highlight lines with warning and error which is cool! though I note that the build traces out of GHC didn't seem to trigger their heuristic.

A first approximation is exit code, of course, and filing an "error" span on a non-zero exit code would be a good step in the right direction.

Ensuring a root span

The second of these is tricky. While we have finally and onException type constructs in real programming languages, in a YAML driven environment having a program that runs before exit no matter what is trickier.

I don't know of any good way to deal with this, other than saying "ensure you run this command at the end no matter what" is the requirement, but it's weak.

@istathar istathar self-assigned this Sep 23, 2022
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

No branches or pull requests

1 participant