-
Notifications
You must be signed in to change notification settings - Fork 297
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(sessions): only recognize session id on root span (where parent is null) #5351
Conversation
if span.parent_id is None: | ||
session_id = get_attribute_value(span.attributes, SpanAttributes.SESSION_ID) | ||
session_user = get_attribute_value(span.attributes, SpanAttributes.USER_ID) | ||
if session_id is not None and (not isinstance(session_id, str) or session_id.strip()): |
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.
if session_id is not None and (not isinstance(session_id, str) or session_id.strip()): | |
if session_id is not None: |
Is the second part of the conditional necessary?
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.
technically it's possible to have ""
(empty string) as the session.id, do we want to record that?
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 see. Probably not would be my guess.
resolves #5347