Skip to content

Commit a2ccb2e

Browse files
committed
Merge branch 'master' into cmanallen/flags-generic-provider
2 parents 3724ffd + 897e2ab commit a2ccb2e

File tree

12 files changed

+172
-73
lines changed

12 files changed

+172
-73
lines changed

app/layout.tsx

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -49,6 +49,17 @@ export default function RootLayout({children}: {children: React.ReactNode}) {
4949
data-api="https://plausible.io/api/event"
5050
src="https://plausible.io/js/script.tagged-events.js"
5151
/>
52+
<Script
53+
async
54+
src="https://widget.kapa.ai/kapa-widget.bundle.js"
55+
data-website-id="cac7cc70-969e-4bc1-a968-55534a839be4"
56+
data-button-hide // do not render kapa ai button
57+
data-modal-override-open-class="kapa-ai-class" // all elements with this class will open the kapa ai modal
58+
data-project-name="Sentry"
59+
data-project-color="#6A5FC1"
60+
data-project-logo="https://docs.sentry.io/_next/static/media/sentry-logo-dark.fc8e1eeb.svg"
61+
data-font-family="var(--font-rubik)"
62+
/>
5263
</html>
5364
);
5465
}

develop-docs/sdk/telemetry/traces/index.mdx

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -232,12 +232,12 @@ If no `tracesSampler` callback is used, the SDK fully inherits sampling decision
232232

233233
The random value is set according to the following rules:
234234

235-
1. When an SDK starts a new trace, `sample_rand` is always set to a random number in the range of `[0, 1]`. This explicitly includes traces that aren't sampled, as well as when the `tracesSampleRate` is set to `0.0` or `1.0`.
235+
1. When an SDK starts a new trace, `sample_rand` is always set to a random number in the range of `[0, 1)` (including 0.0, excluding 1.0). This explicitly includes traces that aren't sampled, as well as when the `tracesSampleRate` is set to `0.0` or `1.0`.
236236
2. It is _recommended_ to generate the random number deterministically using the trace ID as seed or source of randomness. The exact method by which the random number is created is implementation defined and may vary between SDK implementations. See 4. on why this behaviour is desirable.
237237
3. On incoming traces, an SDK assumes the `sample_rand` value along with the rest of the DSC, overriding an existing value if needed.
238238
4. If `sample_rand` is missing on an incoming trace, the SDK creates and from now on propagates a new random number on-the-fly, based on the following rules:
239239
1. If `sample_rate` and `sampled` are propgated, create `sample_rand` so that it adheres to the invariant. This means, for a decision of `True` generate a random number in half-open range `[0, rate)` and for a decision of `False` generate a random number in range `[rate, 1]`.
240-
2. If the sampling decision is missing, generate a random number in range of `[0, 1]`, like for a new trace.
240+
2. If the sampling decision is missing, generate a random number in range of `[0, 1)` (including 0.0, excluding 1.0), like for a new trace.
241241

242242
The SDK should always use the stored random number (`sentry-sample_rand`) for sampling decisions and should no longer rely on `math.random()` or similar functions in tracing code:
243243

docs/platforms/android/index.mdx

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -49,8 +49,6 @@ Select which Sentry features you'd like to install in addition to Error Monitori
4949

5050
Sentry captures data by using an SDK within your application's runtime. These are platform-specific and allow Sentry to have a deep understanding of how your application works.
5151

52-
In addition to capturing errors, you can monitor interactions between multiple services or applications by [enabling tracing](https://docs.sentry.io/concepts/key-terms/tracing/). You can also collect and analyze performance profiles from real users with [profiling](https://docs.sentry.io/product/explore/profiling/). To enable tracing and/or profiling, click the corresponding checkmarks to get the code snippets.
53-
5452
We recommend installing the SDK through our [Sentry Wizard](https://github.com/getsentry/sentry-wizard) by running the following command inside your project directory:
5553

5654
```bash

docs/platforms/apple/common/index.mdx

Lines changed: 101 additions & 27 deletions
Original file line numberDiff line numberDiff line change
@@ -18,23 +18,36 @@ The support for [visionOS](https://developer.apple.com/visionos/) is currently e
1818

1919
## Features
2020

21+
<PlatformSection notSupported={["apple.tvos", "apple.watchos", "apple.visionos"]}>
22+
2123
In addition to capturing errors, you can monitor interactions between multiple services or applications by [enabling tracing](/concepts/key-terms/tracing/). You can also collect and analyze performance profiles from real users with [profiling](/product/explore/profiling/).
2224

25+
</PlatformSection>
26+
27+
<PlatformSection notSupported={["apple.ios", "apple.macos"]}>
28+
29+
In addition to capturing errors, you can monitor interactions between multiple services or applications by [enabling tracing](/concepts/key-terms/tracing/).
30+
31+
</PlatformSection>
32+
2333
Select which Sentry features you'd like to install in addition to Error Monitoring to get the corresponding installation and configuration instructions below.
2434

2535
## Install
2636

27-
<OnboardingOptionButtons
28-
options={[
29-
'error-monitoring',
30-
'performance',
31-
'profiling',
32-
]}
33-
/>
37+
<PlatformSection notSupported={["apple.tvos", "apple.watchos", "apple.visionos"]}>
3438

35-
Sentry captures data by using an SDK within your application's runtime. These are platform-specific and allow Sentry to have a deep understanding of how your application works.
39+
<OnboardingOptionButtons options={['error-monitoring', 'performance', 'profiling']}/>
40+
41+
</PlatformSection>
42+
43+
<PlatformSection notSupported={["apple.ios", "apple.macos"]}>
44+
45+
<OnboardingOptionButtons options={['error-monitoring', 'performance']}/>
46+
47+
</PlatformSection>
3648

37-
In addition to capturing errors, you can monitor interactions between multiple services or applications by [enabling tracing](https://docs.sentry.io/concepts/key-terms/tracing/). You can also collect and analyze performance profiles from real users with [profiling](https://docs.sentry.io/product/profiling/). To enable tracing and/or profiling, click the corresponding checkmarks to get the code snippets.
49+
50+
Sentry captures data by using an SDK within your application's runtime. These are platform-specific and allow Sentry to have a deep understanding of how your application works.
3851

3952
<PlatformSection notSupported={["apple.ios"]}>
4053

@@ -72,8 +85,9 @@ If you prefer, you can also [set up the SDK manually](/platforms/apple/guides/io
7285

7386
To capture all errors, initialize the SDK as soon as possible, such as in your `AppDelegate` `application:didFinishLaunchingWithOptions` method:
7487

88+
<PlatformSection notSupported={["apple.tvos", "apple.watchos", "apple.visionos"]}>
7589

76-
```swift {tabTitle:Swift} {"onboardingOptions": {"performance": "9-12", "profiling": "13-16"}}
90+
```swift {tabTitle:Swift} {"onboardingOptions": {"performance": "9-12", "profiling": "14-24"}}
7791
import Sentry
7892

7993
func application(_ application: UIApplication,
@@ -88,22 +102,22 @@ func application(_ application: UIApplication,
88102
options.tracesSampleRate = 1.0
89103
}
90104

91-
// Manually call startProfiler and stopProfiler to profile any code that runs in between.
92-
SentrySDK.startProfiler()
105+
// Manually call startProfiler and stopProfiler to profile any code that runs in between.
106+
SentrySDK.startProfiler()
93107

94-
//
95-
// ...anything here will be profiled...
96-
//
108+
//
109+
// ...anything here will be profiled...
110+
//
97111

98-
// Calls to stopProfiler are optional - if you don't stop the profiler, it will keep profiling
99-
// your application until the process exits, the app goes to the background, or stopProfiling is called.
100-
SentrySDK.stopProfiler()
112+
// Calls to stopProfiler are optional - if you don't stop the profiler, it will keep profiling
113+
// your application until the process exits, the app goes to the background, or stopProfiling is called.
114+
SentrySDK.stopProfiler()
101115

102116
return true
103117
}
104118
```
105119

106-
```objc {tabTitle:Objective-C} {"onboardingOptions": {"performance": "8-11", "profiling": "12-15"}}
120+
```objc {tabTitle:Objective-C} {"onboardingOptions": {"performance": "8-11", "profiling": "13-23"}}
107121
@import Sentry;
108122

109123
- (BOOL)application:(UIApplication *)application didFinishLaunchingWithOptions:(NSDictionary *)launchOptions {
@@ -117,16 +131,16 @@ func application(_ application: UIApplication,
117131
options.tracesSampleRate = @1.0;
118132
}];
119133

120-
// Manually call startProfiler and stopProfiler to profile any code that runs in between.
121-
[SentrySDK startProfiler];
134+
// Manually call startProfiler and stopProfiler to profile any code that runs in between.
135+
[SentrySDK startProfiler];
122136

123-
//
124-
// ...anything here will be profiled...
125-
//
137+
//
138+
// ...anything here will be profiled...
139+
//
126140

127-
// Calls to stopProfiler are optional - if you don't stop the profiler, it will keep profiling
128-
// your application until the process exits, the app goes to the background, or stopProfiling is called.
129-
[SentrySDK stopProfiler];
141+
// Calls to stopProfiler are optional - if you don't stop the profiler, it will keep profiling
142+
// your application until the process exits, the app goes to the background, or stopProfiling is called.
143+
[SentrySDK stopProfiler];
130144

131145
return YES;
132146
}
@@ -153,6 +167,66 @@ struct SwiftUIApp: App {
153167
}
154168
}
155169
```
170+
</PlatformSection>
171+
172+
<PlatformSection notSupported={["apple.ios", "apple.macos"]}>
173+
174+
```swift {tabTitle:Swift} {"onboardingOptions": {"performance": "9-12"}}
175+
import Sentry
176+
177+
func application(_ application: UIApplication,
178+
didFinishLaunchingWithOptions launchOptions: [UIApplication.LaunchOptionsKey: Any]?) -> Bool {
179+
180+
SentrySDK.start { options in
181+
options.dsn = "___PUBLIC_DSN___"
182+
options.debug = true // Enabled debug when first installing is always helpful
183+
184+
// Set tracesSampleRate to 1.0 to capture 100% of transactions for performance monitoring.
185+
// We recommend adjusting this value in production.
186+
options.tracesSampleRate = 1.0
187+
}
188+
189+
return true
190+
}
191+
```
192+
193+
```objc {tabTitle:Objective-C} {"onboardingOptions": {"performance": "8-11"}}
194+
@import Sentry;
195+
196+
- (BOOL)application:(UIApplication *)application didFinishLaunchingWithOptions:(NSDictionary *)launchOptions {
197+
198+
[SentrySDK startWithConfigureOptions:^(SentryOptions *options) {
199+
options.dsn = @"___PUBLIC_DSN___";
200+
options.debug = YES; // Enabled debug when first installing is always helpful
201+
202+
// Set tracesSampleRate to 1.0 to capture 100% of transactions for performance monitoring.
203+
// We recommend adjusting this value in production.
204+
options.tracesSampleRate = @1.0;
205+
}];
206+
207+
return YES;
208+
}
209+
```
210+
211+
```swift {tabTitle:SwiftUI with App conformer} {"onboardingOptions": {"performance": "9-12"}}
212+
import Sentry
213+
214+
@main
215+
struct SwiftUIApp: App {
216+
init() {
217+
SentrySDK.start { options in
218+
options.dsn = "___PUBLIC_DSN___"
219+
options.debug = true // Enabled debug when first installing is always helpful
220+
221+
// Set tracesSampleRate to 1.0 to capture 100% of transactions for performance monitoring.
222+
// We recommend adjusting this value in production.
223+
options.tracesSampleRate = 1.0
224+
}
225+
}
226+
}
227+
```
228+
229+
</PlatformSection>
156230

157231
## Verify
158232

docs/platforms/javascript/guides/react/features/react-router/v6.mdx

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,10 @@ Update your `Sentry.browserTracingIntegration` to `Sentry.reactRouterV6BrowserTr
1616

1717
<Alert level="warning">
1818

19-
Make sure you call `Sentry.init`, **before** you wrap your `<Routes />` component or the `useRoutes` hook. Otherwise, the routing instrumentation may not work properly.
19+
To ensure proper routing instrumentation, initialize Sentry by calling `Sentry.init` **before**:
20+
- Wrapping your `<Routes />` component
21+
- Using `useRoutes`
22+
- Using `createBrowserRouterV6`
2023

2124
</Alert>
2225

@@ -56,7 +59,7 @@ Sentry.init({
5659
});
5760

5861
const sentryCreateBrowserRouter =
59-
Sentry.wrapCreateBrowserRouter(createBrowserRouter);
62+
Sentry.wrapCreateBrowserRouterV6(createBrowserRouter);
6063

6164
const router = sentryCreateBrowserRouter([
6265
// your routes...

docs/platforms/javascript/guides/react/features/react-router/v7.mdx

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,10 @@ Update your `Sentry.browserTracingIntegration` to `Sentry.reactRouterV7BrowserTr
1717

1818
<Alert level="warning">
1919

20-
Make sure you call `Sentry.init`, **before** you wrap your `<Routes />` component or the `useRoutes` hook. Otherwise, the routing instrumentation may not work properly.
20+
To ensure proper routing instrumentation, initialize Sentry by calling `Sentry.init` **before**:
21+
- Wrapping your `<Routes />` component
22+
- Using `useRoutes`
23+
- Using `createBrowserRouterV7`
2124

2225
</Alert>
2326

docs/platforms/unreal/configuration/environments.mdx

Lines changed: 13 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -4,14 +4,14 @@ description: "Learn how to configure your SDK to tell Sentry about your environm
44
sidebar_order: 30
55
---
66

7-
Environments tell you where an error occurred, whether that's in your production system, your staging server, or elsewhere.
8-
It help you better filter issues, releases, and user feedback in the Issue Details page of sentry.io, which you learn more about in our [documentation that covers using environments](/product/sentry-basics/environments/).
7+
Environments in Sentry let you know where an error occurred, (such as in production, staging server, or another location).
8+
They make it easier to filter issues, releases, and user feedback on the Issue Details page, (which you can navigate to by clicking any issue on the [**Issues**](https://sentry.io/orgredirect/organizations/:orgslug/issues/) page). To learn more, read our docs about [using environments](/product/sentry-basics/environments/).
99

1010
Sentry automatically creates an environment when it receives an event with the `environment` parameter set.
1111

12-
By default, the SDK reports `Editor` when running inside the Unreal Engine Editor.
13-
For shipping builds it'll use `Release` and in other configurations it'll use `FApp::GetBuildConfiguration()`
14-
You can also set the default environment to `Release`, `Development`, or `Debug` in your build configuration or override the environment value programatically.
12+
When running inside the Unreal Engine Editor, the SDK reports the environment as `Editor`. For shipping builds, it defaults to `Release`.
13+
In other configurations it uses the `FApp::GetBuildConfiguration()`.
14+
You can also set the default environment to `Release`, `Development`, or `Debug` in your build configuration, or override it programmatically.
1515

1616
```cpp
1717
FConfigureSettingsDelegate SettingsDelegate;
@@ -29,4 +29,11 @@ USentrySubsystem* SentrySubsystem = GEngine->GetEngineSubsystem<USentrySubsystem
2929
SentrySubsystem->InitializeWithSettings(SettingsDelegate);
3030
```
3131
32-
Environments are case-sensitive. The environment name can't contain newlines, spaces or forward slashes, can't be the string "None", or exceed 64 characters. You can't delete environments, but you can [hide](/product/sentry-basics/environments/#hidden-environments) them.
32+
**Important things to note about environments:**
33+
34+
- Environment names are case-sensitive.
35+
- Names cannot include new lines, spaces, or forward slashes.
36+
- Certain strings, like "None", aren't allowed.
37+
- The maximum length for an environment name is 64 characters.
38+
- Environments can't be deleted, but can be [hidden](/product/sentry-basics/environments/#hidden-environments) if no longer needed.
39+

platform-includes/capture-error/go.mdx

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,11 @@
1-
To capture an event in Go, you can pass any struct implementing an `error` interface to `CaptureException()`. If you use a 3rd party library instead of native `errors` package, we'll do our best to extract a stack trace.
1+
To capture an event in Go, you can pass any struct implementing an `error` interface to `CaptureException()`. If you use a 3rd party library instead of the native `errors` package and it implements the `Unwrap() error` or `Cause() error` method, we'll follow the chain of errors and extract the stack trace from the root cause.
22

33
The SDK is fully compatible with (but not limited to):
44

55
- `github.com/pkg/errors`
66
- `github.com/go-errors/errors`
77
- `github.com/pingcap/errors`
8+
- `github.com/rotisserie/eris`
89

910
If there is an errors package that's not working out of the box, let us know!
1011

src/build/resolveOpenAPI.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ import {DeRefedOpenAPI} from './open-api/types';
88

99
// SENTRY_API_SCHEMA_SHA is used in the sentry-docs GHA workflow in getsentry/sentry-api-schema.
1010
// DO NOT change variable name unless you change it in the sentry-docs GHA workflow in getsentry/sentry-api-schema.
11-
const SENTRY_API_SCHEMA_SHA = '5d9340a8aa68964aa58ac198b5cdad2c7aaca5e9';
11+
const SENTRY_API_SCHEMA_SHA = 'a2907d92817e43576c371270ca6854b472c3509c';
1212

1313
const activeEnv = process.env.GATSBY_ENV || process.env.NODE_ENV || 'development';
1414

src/components/mobileMenu/index.tsx

Lines changed: 2 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -42,12 +42,8 @@ export function MobileMenu({pathname, searchPlatforms}: Props) {
4242
</DropdownMenu.Item>
4343

4444
<DropdownMenu.Item className={styles.DropdownMenuItem} asChild>
45-
<Link
46-
href="https://docsbot.ai/chat/skFEy0qDC01GrRrZ7Crs/EPqsd8nu2XmKzWnd45tL"
47-
target="_blank"
48-
className="mt-2 md:hidden"
49-
>
50-
Ask A Bot
45+
<Link href="#" className="mt-2 kapa-ai-class md:hidden">
46+
Ask AI
5147
</Link>
5248
</DropdownMenu.Item>
5349
<DropdownMenu.Separator className={styles.DropdownMenuSeparator} />

0 commit comments

Comments
 (0)