Skip to content

Commit 7cf574e

Browse files
authored
chore: Exceptions tab improvements (#535)
* Feature tracking * Remove console.log * Hide streaming progress * Fix escaping
1 parent 86942f7 commit 7cf574e

2 files changed

Lines changed: 6 additions & 4 deletions

File tree

src/components/Explore/TracesByService/Tabs/Exceptions/ExceptionsScene.tsx

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -22,10 +22,12 @@ import {
2222
EMPTY_STATE_ERROR_MESSAGE,
2323
EMPTY_STATE_ERROR_REMEDY_MESSAGE,
2424
explorationDS,
25+
filterStreamingProgressTransformations,
2526
} from '../../../../../utils/shared';
2627
import { getTraceByServiceScene, getFiltersVariable } from '../../../../../utils/utils';
2728
import { buildExceptionsQuery } from 'components/Explore/queries/exceptions';
2829
import { aggregateExceptions } from './ExceptionUtils';
30+
import { reportAppInteraction, USER_EVENTS_ACTIONS, USER_EVENTS_PAGES } from 'utils/analytics';
2931

3032
export interface ExceptionsSceneState extends SceneObjectState {
3133
panel?: SceneFlexLayout;
@@ -49,7 +51,7 @@ export class ExceptionsScene extends SceneObjectBase<ExceptionsSceneState> {
4951

5052
const dataTransformer = this.state.$data as SceneDataTransformer;
5153
dataTransformer.setState({
52-
transformations: [this.createTransformation()],
54+
transformations: [...filterStreamingProgressTransformations, this.createTransformation()],
5355
});
5456

5557
this.addActivationHandler(() => {
@@ -287,8 +289,6 @@ export class ExceptionsScene extends SceneObjectBase<ExceptionsSceneState> {
287289
},
288290
};
289291

290-
console.log(sparklineData);
291-
292292
return (
293293
<div className={styles.sparklineContainer}>
294294
<Sparkline
@@ -322,6 +322,7 @@ export class ExceptionsScene extends SceneObjectBase<ExceptionsSceneState> {
322322
if (rowIndex !== undefined) {
323323
const message = event.origin?.field?.values?.[rowIndex];
324324
if (message) {
325+
reportAppInteraction(USER_EVENTS_PAGES.analyse_traces, USER_EVENTS_ACTIONS.analyse_traces.exception_message_clicked);
325326
this.navigateToTracesWithFilter(message);
326327
}
327328
}
@@ -362,7 +363,7 @@ export class ExceptionsScene extends SceneObjectBase<ExceptionsSceneState> {
362363
.replace(/[\n\r\t]/g, ' ')
363364
.replace(/\s+/g, ' ')
364365
.replace(/\\/g, '\\\\')
365-
.replace(/"/g, '\\"')
366+
.replace(/"/g, '\"')
366367
.trim();
367368
}
368369

src/utils/analytics.ts

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -44,6 +44,7 @@ export const USER_EVENTS_ACTIONS = {
4444
span_list_columns_changed: 'span_list_columns_changed',
4545
toggle_bookmark_clicked: 'toggle_bookmark_clicked',
4646
primary_signal_changed: 'primary_signal_changed',
47+
exception_message_clicked: 'exception_message_clicked',
4748
},
4849
[USER_EVENTS_PAGES.home]: {
4950
homepage_initialized: 'homepage_initialized',

0 commit comments

Comments
 (0)