MCPcopy Index your code
hub / github.com/getsentry/sentry-javascript / _shouldIgnoreStreamedSpan

Function _shouldIgnoreStreamedSpan

packages/core/src/tracing/trace.ts:637–652  ·  view source on GitHub ↗
(client: Client | undefined, spanArguments: SentrySpanArguments)

Source from the content-addressed store, hash-verified

635
636/* Checks if `ignoreSpans` applies (extracted for bundle size)*/
637function _shouldIgnoreStreamedSpan(client: Client | undefined, spanArguments: SentrySpanArguments): boolean {
638 const ignoreSpans = client?.getOptions().ignoreSpans;
639
640 if (!client || !hasSpanStreamingEnabled(client) || !ignoreSpans?.length) {
641 return false;
642 }
643
644 return shouldIgnoreSpan(
645 {
646 description: spanArguments.name || '',
647 op: spanArguments.attributes?.[SEMANTIC_ATTRIBUTE_SENTRY_OP] || spanArguments.op,
648 attributes: spanArguments.attributes,
649 },
650 ignoreSpans,
651 );
652}
653
654function _isIgnoredSpan(span: Span): span is SentryNonRecordingSpan {
655 return spanIsNonRecordingSpan(span) && span.dropReason === 'ignored';

Callers 1

createChildOrRootSpanFunction · 0.85

Calls 3

hasSpanStreamingEnabledFunction · 0.90
shouldIgnoreSpanFunction · 0.90
getOptionsMethod · 0.65

Tested by

no test coverage detected