Skip to content

Commit 839b137

Browse files
authored
chore(github): Adjust BUGBOT.md rules to flag invalid op and origin values during review (#18352)
based on the invalid origin values reported in #18350 (and a bunch more invalid values in other SDKs) let's make bugbot a bit smarter to flag stuff like this in the future
1 parent 9f0e206 commit 839b137

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

.cursor/BUGBOT.md

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,11 @@ Do not flag the issues below if they appear in tests.
3232

3333
- When calling any `startSpan` API (`startInactiveSpan`, `startSpanManual`, etc), always ensure that the following span attributes are set:
3434
- `SEMANTIC_ATTRIBUTE_SENTRY_ORIGIN` (`'sentry.origin'`) with a proper span origin
35+
- a proper origin must only contain [a-z], [A-Z], [0-9], `_` and `.` characters.
36+
- flag any non-conforming origin values as invalid and link to the trace origin specification (https://develop.sentry.dev/sdk/telemetry/traces/trace-origin/)
3537
- `SEMANTIC_ATTRIBUTE_SENTRY_OP` (`'sentry.op'`) with a proper span op
38+
- Span ops should be lower case only, and use snake_case. The `.` character is used to delimit op parts.
39+
- flag any non-conforming origin values as invalid and link to the span op specification (https://develop.sentry.dev/sdk/telemetry/traces/span-operations/)
3640
- When calling `captureException`, always make sure that the `mechanism` is set:
3741
- `handled`: must be set to `true` or `false`
3842
- `type`: must be set to a proper origin (i.e. identify the integration and part in the integration that caught the exception).

0 commit comments

Comments
 (0)