fix: Disable useSessionId query when traceId input is undefined #1451
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Closes #1449
Closes HDX-2992
Summary
This PR prevents HyperDX from issuing an invalid query (described in #1449) by disabling the query for sessions when a trace ID is not available. This often happened not just for events without a trace ID but also immediately after opening the side panel while a valid traceId was still loading.
Updating the types to reflect the possibility that trace ID is undefined also exposed the fact that we try to show the trace waterfall and row overview panels on the trace panel even when there is no trace id. This has been fixed.
Before
Screen.Recording.2025-12-05.at.9.50.43.AM.mov
After
No invalid query is issued:
Screen.Recording.2025-12-05.at.9.51.51.AM.mov
When there is no trace id, we don't attempt to render the waterfall:
