You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Commit 475d31e
Browse filesBrowse the repository at this point in the historyBrowse files
`sdk/valid-span-origin` now requires the category part of a literal
origin to be a span op category, as the trace origin spec says. It
need not match the op of the same span: `auto.ui.angular` on a `router`
span is valid. This replaces the AGENTS.md line about origin categories.
`faas` is allowed as a known exception. The `auto.faas.cloudflare.*`
origins break the spec, but renaming them would break user queries in a
minor release, so a TODO(v12) marks the rename. The runtime metrics
integrations disable the rule, because the spec covers span and log
origins, not metric origins.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
// Span op categories from https://develop.sentry.dev/sdk/telemetry/traces/span-operations/
21
+
constCATEGORIES=newSet([
22
+
'ai',
23
+
'app',
24
+
'browser',
25
+
'cache',
26
+
'console',
27
+
'db',
28
+
'event',
29
+
'file',
30
+
'function',
31
+
'graphql',
32
+
'grpc',
33
+
'http',
34
+
'log',
35
+
'mark',
36
+
'measure',
37
+
'middleware',
38
+
'navigation',
39
+
'object',
40
+
'pageload',
41
+
'queue',
42
+
'resource',
43
+
'rpc',
44
+
'serialize',
45
+
'socket',
46
+
'subprocess',
47
+
'template',
48
+
'topic',
49
+
'ui',
50
+
'view',
51
+
'websocket',
52
+
// TODO(v12): Rename the `auto.faas.cloudflare.*` origins to
53
+
// `auto.function.cloudflare.*`, as AWS and GCP use, and drop this entry.
54
+
// `faas` is not a span op category, but renaming an origin breaks user
55
+
// queries that match it, so it waits for a major.
56
+
'faas',
57
+
]);
58
+
20
59
functiongetKeyName(node,computed){
21
60
if(computed&&node.type==='Identifier'){
22
61
returnnode.name;
@@ -39,6 +78,8 @@ module.exports = {
39
78
"Span origin '{{origin}}' must be '<type>.<category>.<integration_name>.<integration_part>': type 'auto' or 'manual', at most four parts, only [a-zA-Z0-9_] in a part. See https://develop.sentry.dev/sdk/telemetry/traces/trace-origin/",
40
79
toolingPart:
41
80
"Span origin '{{origin}}' names tooling ('{{part}}'). The origin identifies the integration, not how it is built.",
81
+
badCategory:
82
+
"Span origin '{{origin}}' has category '{{category}}', which is not a span op category. See https://develop.sentry.dev/sdk/telemetry/traces/span-operations/",
0 commit comments