Received the following error on a instrument_anthopic call.
File ~/an-env/lib/python3.11/site-packages/logfire/_internal/main.py:1012, in Logfire.instrument_anthropic(self, anthropic_client, suppress_other_instrumentation)
962 """Instrument an Anthropic client so that spans are automatically created for each request.
963
964 The following methods are instrumented for both the sync and the async clients:
(...)
1008 Use of this context manager is optional.
1009 """
1010 import anthropic
-> 1012 from .integrations.llm_providers.anthropic import get_endpoint_config, is_async_client, on_response
1013 from .integrations.llm_providers.llm_provider import instrument_llm_provider
1015 self._warn_if_not_initialized_for_instrumentation()
File ~/an-env/lib/python3.11/site-packages/logfire/_internal/integrations/llm_providers/anthropic.py:6
3 from typing import TYPE_CHECKING, Any
5 import anthropic
----> 6 from anthropic.types import Message, RawContentBlockDeltaEvent, RawContentBlockStartEvent, TextBlock, TextDelta
8 from .types import EndpointConfig
10 if TYPE_CHECKING:
ImportError: cannot import name 'RawContentBlockDeltaEvent' from 'anthropic.types' (/Users/someuser/an-env/lib/python3.11/site-packages/anthropic/types/__init__.py)
### Python, Logfire & OS Versions, related packages (not required)
Description
Received the following error on a
instrument_anthopic
call.