File tree Expand file tree Collapse file tree 2 files changed +10
-3
lines changed Expand file tree Collapse file tree 2 files changed +10
-3
lines changed Original file line number Diff line number Diff line change @@ -69,6 +69,7 @@ def iter_default_integrations(with_auto_enabling_integrations):
69
69
70
70
_AUTO_ENABLING_INTEGRATIONS = [
71
71
"sentry_sdk.integrations.aiohttp.AioHttpIntegration" ,
72
+ "sentry_sdk.integrations.anthropic.AnthropicIntegration" ,
72
73
"sentry_sdk.integrations.ariadne.AriadneIntegration" ,
73
74
"sentry_sdk.integrations.arq.ArqIntegration" ,
74
75
"sentry_sdk.integrations.asyncpg.AsyncPGIntegration" ,
Original file line number Diff line number Diff line change 12
12
package_version ,
13
13
)
14
14
15
- from anthropic .resources import Messages
16
-
17
15
from typing import TYPE_CHECKING
18
16
17
+ try :
18
+ from anthropic .resources import Messages
19
+
20
+ if TYPE_CHECKING :
21
+ from anthropic .types import MessageStreamEvent
22
+ except ImportError :
23
+ raise DidNotEnable ("Anthropic not installed" )
24
+
25
+
19
26
if TYPE_CHECKING :
20
27
from typing import Any , Iterator
21
- from anthropic .types import MessageStreamEvent
22
28
from sentry_sdk .tracing import Span
23
29
24
30
You can’t perform that action at this time.
0 commit comments