Skip to content

Commit

Permalink
Add page for pure_eval integration (#1907)
Browse files Browse the repository at this point in the history
  • Loading branch information
alexmojaki authored Jul 22, 2020
1 parent 3d38104 commit 6067f53
Show file tree
Hide file tree
Showing 3 changed files with 25 additions and 0 deletions.
1 change: 1 addition & 0 deletions __tests__/__snapshots__/documentation.js.snap
Original file line number Diff line number Diff line change
Expand Up @@ -377,6 +377,7 @@ Array [
"platforms/python/index.html",
"platforms/python/logging/index.html",
"platforms/python/migration/index.html",
"platforms/python/pure_eval/index.html",
"platforms/python/pyramid/index.html",
"platforms/python/pyspark/index.html",
"platforms/python/redis/index.html",
Expand Down
1 change: 1 addition & 0 deletions src/collections/_documentation/platforms/python/index.md
Original file line number Diff line number Diff line change
Expand Up @@ -267,6 +267,7 @@ For more information, see:

- [Logging](/platforms/python/logging/)
- [GNU Backtrace](/platforms/python/gnu_backtrace/)
- [pure_eval](/platforms/python/pure_eval/)
- [Redis](/platforms/python/redis/)
- [SQLAlchemy](/platforms/python/sqlalchemy/)

Expand Down
23 changes: 23 additions & 0 deletions src/collections/_documentation/platforms/python/pure_eval.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
---
title: pure_eval
sidebar_order: 9
---

{% version_added 0.16.2 %}

This integration uses [`pure_eval`](https://github.com/alexmojaki/pure_eval) to safely evaluate additional expressions in the source code and display their values alongside other local variables.

**This integration is experimental.** It may be removed in minor versions.

Python version 3.5 or greater is required.

To install dependencies, either `pip install 'sentry-sdk[pure_eval]'` or `pip install pure_eval executing asttokens`.

Add ``PureEvalIntegration()`` to your ``integrations`` list:

```python
import sentry_sdk
from sentry_sdk.integrations.pure_eval import PureEvalIntegration

sentry_sdk.init("___PUBLIC_DSN___", integrations=[PureEvalIntegration()])
```

0 comments on commit 6067f53

Please sign in to comment.