[python] update anthropic llmobs tests for new cache ttl metrics#6480
[python] update anthropic llmobs tests for new cache ttl metrics#6480
Conversation
|
|
sabrenner
left a comment
There was a problem hiding this comment.
i would:
- update the manifest to say these tests are a
missing_feature, so that we can land these test changes. - update dd-trace-py to use the most recent system-test hash (if that's still the process) - then your PR should pass and these
missing_featurewillXPASS - Then, once the feature is released, we can add the version to the manifest for these tests.
|
✨ Fix all issues with BitsAI or with Cursor
|
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 0bb83ed092
ℹ️ About Codex in GitHub
Codex has been enabled to automatically review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
When you sign up for Codex through ChatGPT, Codex can also answer questions or update the PR, like "@codex address that feedback".
| write_span_event, read_span_event = span_events | ||
|
|
||
| assert write_span_event["metrics"]["cache_write_input_tokens"] == 6163 | ||
| assert write_span_event["metrics"]["ephemeral_5m_input_tokens"] == 6163 |
There was a problem hiding this comment.
Gate prompt-caching TTL assertion to Python
test_create_prompt_caching is shared across libraries, but this new assertion is unconditional. manifests/nodejs.yml:1590-1599 still enables TestAnthropicLlmObsMessages for Node.js and explicitly marks the other Anthropic methods as missing_feature because the TTL breakdown metrics are not released there yet; this prompt-caching test is not skipped, so Node.js runs will now fail with a missing ephemeral_5m_input_tokens metric even though only the Python manifest was updated.
Useful? React with 👍 / 👎.
|
Keeping as draft until Python tracer containing fix is released. |
Motivation
Account for additional cache creation ttl breakdown metrics in the anthropic integration.
Changes
Workflow
🚀 Once your PR is reviewed and the CI green, you can merge it!
🛟 #apm-shared-testing 🛟
Reviewer checklist
tests/ormanifests/is modified ? I have the approval from R&P teambuild-XXX-imagelabel is present