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

Fix SentryTransaction#getStatus NPE #1273

Merged
merged 4 commits into from
Feb 19, 2021
Merged

Fix SentryTransaction#getStatus NPE #1273

merged 4 commits into from
Feb 19, 2021

Conversation

maciejwalkowiak
Copy link
Contributor

📜 Description

Fix SentryTransaction#getStatus NPE

💡 Motivation and Context

Fixes #1268.

💚 How did you test it?

📝 Checklist

  • I reviewed the submitted code
  • I added tests to verify the changes
  • I updated the docs if needed
  • No breaking changes

Comment on lines 241 to 242
final SpanContext trace = this.getContexts().getTrace();
return trace != null ? trace.getStatus() : null;
Copy link
Contributor

Choose a reason for hiding this comment

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

why not context.getStatus()?
I could set a status and check for it, why do I need to wait the transaction to be finished?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Thanks Manoel, good point.

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.

SentryTransaction.getStatus throws NPE
2 participants