Skip to content
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion static/app/utils/analytics/replayAnalyticsEvents.tsx
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import type {LayoutKey} from 'sentry/utils/replays/hooks/useReplayLayout';
import type {Output} from 'sentry/views/explore/replays/detail/network/details/getOutputType';
import type {Output} from 'sentry/views/explore/replays/detail/network/details/output';

export type ReplayEventParameters = {
'replay.ai-summary.chapter-clicked': {
Expand Down
11 changes: 7 additions & 4 deletions static/app/utils/replays/types.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -13,8 +13,6 @@ import type {
} from '@sentry/react';
import invariant from 'invariant';

import type {Event} from 'sentry/types/event';

export type {serializedNodeWithId} from '@sentry-internal/rrweb-snapshot';
export type {fullSnapshotEvent, incrementalSnapshotEvent} from '@sentry-internal/rrweb';

Expand Down Expand Up @@ -214,8 +212,13 @@ export function isFeedbackFrame(frame: ReplayFrame | undefined): frame is Feedba
return Boolean(frame && 'category' in frame && frame.category === 'feedback');
}

export function isHydrateCrumb(item: BreadcrumbFrame | Event): item is BreadcrumbFrame {
return 'category' in item && item.category === 'replay.hydrate-error';
export function isHydrateCrumb(item: unknown): item is BreadcrumbFrame {
return (
typeof item === 'object' &&
item !== null &&
'category' in item &&
item.category === 'replay.hydrate-error'
);
}

export function isSpanFrame(frame: ReplayFrame | undefined): frame is SpanFrame {
Expand Down
Original file line number Diff line number Diff line change
@@ -1,17 +1,9 @@
import {isRequestFrame} from 'sentry/utils/replays/resourceFrame';
import {Output} from 'sentry/views/explore/replays/detail/network/details/output';
import type {SectionProps} from 'sentry/views/explore/replays/detail/network/details/sections';
import type {TabKey} from 'sentry/views/explore/replays/detail/network/details/tabs';

export enum Output {
SETUP = 'setup',
UNSUPPORTED = 'unsupported',
URL_SKIPPED = 'url_skipped',
BODY_SKIPPED = 'body_skipped',
BODY_PARSE_ERROR = 'body_parse_error',
BODY_PARSE_TIMEOUT = 'body_parse_timeout',
UNPARSEABLE_BODY_TYPE = 'unparseable_body_type',
DATA = 'data',
}
export {Output};

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

re-export.

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

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

AAAAGH


type Args = {
isCaptureBodySetup: boolean;
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
export enum Output {
SETUP = 'setup',
UNSUPPORTED = 'unsupported',
URL_SKIPPED = 'url_skipped',
BODY_SKIPPED = 'body_skipped',
BODY_PARSE_ERROR = 'body_parse_error',
BODY_PARSE_TIMEOUT = 'body_parse_timeout',
UNPARSEABLE_BODY_TYPE = 'unparseable_body_type',
DATA = 'data',
}
Loading