Skip to content

Commit 7062170

Browse files
authored
Python: Added some missing options (#15052)
<!-- Use this checklist to make sure your PR is ready for merge. You may delete any sections you don't need. --> ## DESCRIBE YOUR PR Add the following config options for Python SDK: - `spotlight` - `auto_session_tracking`. As well as formatting the document. Preview: https://sentry-docs-git-antonpirker-pythonmore-missing-options.sentry.dev/platforms/python/configuration/options/ refs #12606 ## IS YOUR CHANGE URGENT? Help us prioritize incoming PRs by letting us know when the change needs to go live. - [ ] Urgent deadline (GA date, etc.): <!-- ENTER DATE HERE --> - [ ] Other deadline: <!-- ENTER DATE HERE --> - [x] None: Not urgent, can wait up to 1 week+ ## SLA - Teamwork makes the dream work, so please add a reviewer to your PRs. - Please give the docs team up to 1 week to review your PR unless you've added an urgent due date to it. Thanks in advance for your help! ## PRE-MERGE CHECKLIST *Make sure you've checked the following before merging your changes:* - [ ] Checked Vercel preview for correctness, including links - [ ] PR was reviewed and approved by any necessary SMEs (subject matter experts) - [ ] PR was reviewed and approved by a member of the [Sentry docs team](https://github.com/orgs/getsentry/teams/docs) ## LEGAL BOILERPLATE <!-- Sentry employees and contractors can delete or ignore this section. --> Look, I get it. The entity doing business as "Sentry" was incorporated in the State of Delaware in 2015 as Functional Software, Inc. and is gonna need some rights from me in order to utilize my contributions in this here PR. So here's the deal: I retain all rights, title and interest in and to my contributions, and by keeping this boilerplate intact I confirm that Sentry can use, modify, copy, and redistribute my contributions, under Sentry's choice of terms. ## EXTRA RESOURCES - [Sentry Docs contributor guide](https://docs.sentry.io/contributing/)
1 parent 91ab345 commit 7062170

File tree

1 file changed

+21
-9
lines changed

1 file changed

+21
-9
lines changed

docs/platforms/python/configuration/options.mdx

Lines changed: 21 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -16,17 +16,17 @@ Options that can be read from an environment variable (`SENTRY_DSN`, `SENTRY_ENV
1616

1717
<SdkOption name='dsn' type='str' envVar='SENTRY_DSN' defaultValue='None'>
1818

19-
The DSN tells the SDK where to send the events. If this option is not set, the SDK will just not send any data. The `dsn` config option takes precedence over the environment variable. Learn more about [DSN utilization](/product/sentry-basics/dsn-explainer/#dsn-utilization).
19+
The DSN tells the SDK where to send the events. If this option is not set, the SDK will just not send any data. The `dsn` config option takes precedence over the environment variable. Learn more about [DSN utilization](/product/sentry-basics/dsn-explainer/#dsn-utilization).
2020

21-
<PlatformContent includePath="configuration/dsn" />
21+
<PlatformContent includePath="configuration/dsn" />
2222

2323
</SdkOption>
2424

2525
<SdkOption name='debug' type='bool' defaultValue='False' envVar='SENTRY_DEBUG'>
2626

27-
Turns debug mode on or off. When `True`, the SDK will attempt to print out debugging information. This can be useful if something goes wrong with event sending. The default is always `False`. It's generally not recommended to turn it on in production because of the increase in log output.
27+
Turns debug mode on or off. When `True`, the SDK will attempt to print out debugging information. This can be useful if something goes wrong with event sending. The default is always `False`. It's generally not recommended to turn it on in production because of the increase in log output.
2828

29-
The `debug` config option takes precedence over the environment variable.
29+
The `debug` config option takes precedence over the environment variable.
3030

3131
</SdkOption>
3232

@@ -48,6 +48,12 @@ The `environment` config option takes precedence over the environment variable.
4848

4949
</SdkOption>
5050

51+
<SdkOption name="spotlight" type='str | bool' envVar='SENTRY_SPOTLIGHT' defaultValue='None'>
52+
53+
Enable [Sentry Spotlight](https://github.com/getsentry/spotlight). Specify the URL that Spotlight is running on. If set to the boolean `True` the default Spotlight URL `"http://localhost:8969/stream"` is used.
54+
55+
</SdkOption>
56+
5157
<SdkOption name="dist" type='str' defaultValue='None'>
5258

5359
The distribution of the application. Distributions are used to disambiguate build or deployment variants of the same release of an application. The dist can be for example a build number.
@@ -71,9 +77,9 @@ If this configuration option is specified, the `sample_rate` option is ignored.
7177
<SdkOption name='ignore_errors' type='list' defaultValue='[]'>
7278
A list of exception class names that shouldn't be sent to Sentry. Errors that are an instance of these exceptions or a subclass of them, will be filtered out before they're sent to Sentry.
7379

74-
By default, all errors are sent.
75-
</SdkOption>
80+
By default, all errors are sent.
7681

82+
</SdkOption>
7783

7884
<SdkOption name="max_breadcrumbs" type='int' defaultValue='100'>
7985

@@ -192,6 +198,12 @@ Set this boolean to `False` to disable sending of client reports. Client reports
192198

193199
</SdkOption>
194200

201+
<SdkOption name="auto_session_tracking" type='bool' defaultValue='True'>
202+
203+
Whether sessions should be automatically recorded and sent to Sentry.
204+
205+
</SdkOption>
206+
195207
## Integration Configuration
196208

197209
<SdkOption name="integrations" type='list[sentry_sdk.integrations.Integration]' defaultValue='[]'>
@@ -203,6 +215,7 @@ List of integrations to enable in addition to [auto-enabling integrations](/plat
203215
<SdkOption name="disabled_integrations" type='list[sentry_sdk.integrations.Integration]' defaultValue='[]'>
204216

205217
List of integrations that will be disabled. This setting can be used to explicitly turn off specific [auto-enabling](/platforms/python/integrations/#available-integrations) or [default](/platforms/python/integrations/default-integrations/) integrations.
218+
206219
</SdkOption>
207220

208221
<SdkOption name="auto_enabling_integrations" type='bool' defaultValue='True'>
@@ -218,6 +231,7 @@ When set to `False`, no auto-enabling integrations will be enabled by default, e
218231
Configures whether [default integrations](/platforms/python/integrations/default-integrations/) should be enabled.
219232

220233
Setting `default_integrations` to `False` disables all default integrations **as well as all auto-enabling integrations**, unless they are specifically added in the `integrations` option, described above.
234+
221235
</SdkOption>
222236

223237
## Hooks
@@ -257,14 +271,13 @@ New in SDK version `2.35.0`. Prior to `2.35.0`, this option was experimental.
257271

258272
<PlatformContent includePath="/performance/traces-sampler-config-option" />
259273

260-
261274
## Transport Options
262275

263276
Transports are used to send events to Sentry. Transports can be customized to some degree to better support highly specific deployments.
264277

265278
<SdkOption name="transport" type='sentry_sdk.transport.Transport' defaultValue='None'>
266279

267-
Switches out the transport used to send events. How this works depends on the SDK. It can, for instance, be used to capture events for unit-testing or to send it through some more complex setup that requires proxy authentication.
280+
Switches out the transport used to send events. How this works depends on the SDK. It can, for instance, be used to capture events for unit-testing or to send it through some more complex setup that requires proxy authentication.
268281

269282
</SdkOption>
270283

@@ -432,7 +445,6 @@ A number between `0` and `1`, controlling the percentage chance a given session
432445

433446
</SdkOption>
434447

435-
436448
## Logs Options
437449

438450
<SdkOption name="enable_logs" type='bool' defaultValue='False'>

0 commit comments

Comments
 (0)