ref(anthropic): Factor out streamed result handling #11495
test-integrations-graphql.yml
on: pull_request
Matrix: GraphQL
All GraphQL tests passed
3s
Annotations
27 warnings
|
GraphQL (3.11, ubuntu-22.04)
❌ Patch coverage check failed: 0.00% < target 80%
|
|
Unprotected _iterator access can crash user applications when stream=True response lacks _iterator attribute:
sentry_sdk/integrations/anthropic.py#L514
The refactored code accesses `result._iterator` directly (lines 403, 481) without verifying the attribute exists, and the call to `_patch_streaming_response_iterator` (line 515) is not wrapped in `capture_internal_exceptions()`. Previously, the streaming path was inside `capture_internal_exceptions()` with `hasattr(result, "_iterator")` check. If `stream=True` is passed but the response object doesn't have `_iterator` (e.g., API version mismatch or unexpected response type), an unhandled `AttributeError` will propagate to the user's application instead of being gracefully logged.
|
|
GraphQL (3.6, ubuntu-22.04)
❌ Patch coverage check failed: 0.00% < target 80%
|
|
GraphQL (3.6, ubuntu-22.04)
Failed to upload coverage artifact: Failed to CreateArtifact: Received non-retryable error: Failed request: (409) Conflict: an artifact with this name already exists on the workflow run
|
|
GraphQL (3.6, ubuntu-22.04)
Failed to upload test artifact: Failed to CreateArtifact: Received non-retryable error: Failed request: (409) Conflict: an artifact with this name already exists on the workflow run
|
|
Streaming response handling no longer protected by capture_internal_exceptions:
sentry_sdk/integrations/anthropic.py#L513
The streaming path now checks `kwargs.get("stream", False)` and calls `_patch_streaming_response_iterator` before entering the `capture_internal_exceptions()` block. Previously, the streaming detection (`hasattr(result, "_iterator")`) was inside the exception handling block. If `stream=True` is passed but the result unexpectedly lacks `_iterator` (e.g., API behavior change, error responses), an `AttributeError` will propagate instead of being gracefully handled, potentially breaking the instrumented code path.
|
|
GraphQL (3.9, ubuntu-22.04)
❌ Patch coverage check failed: 0.00% < target 80%
|
|
GraphQL (3.9, ubuntu-22.04)
Failed to upload coverage artifact: Failed to CreateArtifact: Received non-retryable error: Failed request: (409) Conflict: an artifact with this name already exists on the workflow run
|
|
GraphQL (3.9, ubuntu-22.04)
Failed to upload test artifact: Failed to CreateArtifact: Received non-retryable error: Failed request: (409) Conflict: an artifact with this name already exists on the workflow run
|
|
GraphQL (3.8, ubuntu-22.04)
❌ Patch coverage check failed: 0.00% < target 80%
|
|
GraphQL (3.8, ubuntu-22.04)
Failed to upload coverage artifact: Failed to CreateArtifact: Received non-retryable error: Failed request: (409) Conflict: an artifact with this name already exists on the workflow run
|
|
GraphQL (3.8, ubuntu-22.04)
Failed to upload test artifact: Failed to CreateArtifact: Received non-retryable error: Failed request: (409) Conflict: an artifact with this name already exists on the workflow run
|
|
GraphQL (3.12, ubuntu-22.04)
❌ Patch coverage check failed: 0.00% < target 80%
|
|
GraphQL (3.12, ubuntu-22.04)
Failed to upload coverage artifact: Failed to CreateArtifact: Received non-retryable error: Failed request: (409) Conflict: an artifact with this name already exists on the workflow run
|
|
GraphQL (3.12, ubuntu-22.04)
Failed to upload test artifact: Failed to CreateArtifact: Received non-retryable error: Failed request: (409) Conflict: an artifact with this name already exists on the workflow run
|
|
GraphQL (3.10, ubuntu-22.04)
❌ Patch coverage check failed: 0.00% < target 80%
|
|
GraphQL (3.10, ubuntu-22.04)
Failed to upload coverage artifact: Failed to CreateArtifact: Received non-retryable error: Failed request: (409) Conflict: an artifact with this name already exists on the workflow run
|
|
GraphQL (3.10, ubuntu-22.04)
Failed to upload test artifact: Failed to CreateArtifact: Received non-retryable error: Failed request: (409) Conflict: an artifact with this name already exists on the workflow run
|
|
GraphQL (3.14t, ubuntu-22.04)
❌ Patch coverage check failed: 0.00% < target 80%
|
|
GraphQL (3.14t, ubuntu-22.04)
Failed to upload coverage artifact: Failed to CreateArtifact: Received non-retryable error: Failed request: (409) Conflict: an artifact with this name already exists on the workflow run
|
|
GraphQL (3.14t, ubuntu-22.04)
Failed to upload test artifact: Failed to CreateArtifact: Received non-retryable error: Failed request: (409) Conflict: an artifact with this name already exists on the workflow run
|
|
GraphQL (3.14, ubuntu-22.04)
❌ Patch coverage check failed: 0.00% < target 80%
|
|
GraphQL (3.14, ubuntu-22.04)
Failed to upload coverage artifact: Failed to CreateArtifact: Received non-retryable error: Failed request: (409) Conflict: an artifact with this name already exists on the workflow run
|
|
GraphQL (3.14, ubuntu-22.04)
Failed to upload test artifact: Failed to CreateArtifact: Received non-retryable error: Failed request: (409) Conflict: an artifact with this name already exists on the workflow run
|
|
GraphQL (3.13, ubuntu-22.04)
❌ Patch coverage check failed: 0.00% < target 80%
|
|
GraphQL (3.13, ubuntu-22.04)
Failed to upload coverage artifact: Failed to CreateArtifact: Received non-retryable error: Failed request: (409) Conflict: an artifact with this name already exists on the workflow run
|
|
GraphQL (3.13, ubuntu-22.04)
Failed to upload test artifact: Failed to CreateArtifact: Received non-retryable error: Failed request: (409) Conflict: an artifact with this name already exists on the workflow run
|
Artifacts
Produced during runtime
| Name | Size | Digest | |
|---|---|---|---|
|
codecov-coverage-results-webb-anthropic-separate-output-handling-test-graphql
|
104 KB |
sha256:93ce898e8d8215d27ed0da6da7322a697166017d3f43a136348b18b0bf70f383
|
|
|
codecov-test-results-webb-anthropic-separate-output-handling-test-graphql
|
230 Bytes |
sha256:488361f232a0d151d029782f59d4301bed02b6853fc4e2567d360e207e399fca
|
|