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

feat: /usr/bin/script wrapper to send full tty output to sentry #124

Open
wants to merge 6 commits into
base: main
Choose a base branch
from

Conversation

joshuarli
Copy link
Member

@joshuarli joshuarli commented Jun 10, 2024

closes #91

devenv now executes itself with script to tee the full tty output into a log file, which is then uploaded to sentry as an attachent to an event in the case of an unsuccessful exit.

I wasn't able to find a way to upload an attachment to an event after-the-fact though, so we're missing out on any detailed stacktrace that occured in devenv.

Events are grouped under user@host so we can easily see someone's issue.

TODO: fetch the event title (based on returned event id) because these attachment names are not that helpful.
Probably as a followup though. https://docs.sentry.io/api/events/retrieve-an-event-for-a-project/

image

@getsentry getsentry deleted a comment from sentry-io bot Jun 10, 2024
@joshuarli joshuarli requested a review from a team June 17, 2024 17:51
devenv/main.py Outdated
if rc == 0:
return rc

# i'd love to be able to send a full event in the child then
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I wonder if we can do something something trace id and have both exist? and just link them after the fact?

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

ahhh that might work, i'm thinking we start a transaction in the parent and start a span for the child process then only transaction.finish() if an error happens in the child

not sure what the transaction would look like in sentry ui (like, can we easily see the child error event) but gonna give it a go

joshuarli added a commit to getsentry/sentry that referenced this pull request Jul 1, 2024
)

This reverts commit 09cdabf. Wasn't
roll forwardable anyways since `make instlal-py-dev` goes through do.sh,
which I plan on removing.

Functionality will be preserved as part of
getsentry/devenv#124 where span durations would
work.
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.

Sentry errors currently contain no useful information because of stdout/stderr and interactivity
2 participants