Skip to content

.

2eb772e
Select commit
Loading
Failed to load commit list.
Merged

feat(redis): Support streaming spans #6083

.
2eb772e
Select commit
Loading
Failed to load commit list.
@sentry/warden / warden: code-review completed Apr 22, 2026 in 2m 59s

2 issues

code-review: Found 2 issues (2 medium)

Medium

Missing test coverage for new span streaming functionality - `sentry_sdk/integrations/redis/_sync_common.py:40-56`

The PR introduces significant new functionality for span streaming support but the PR description explicitly indicates tests have not been added yet. This includes conditional logic for streaming spans in both patch_redis_pipeline and patch_redis_client functions. Without tests, regressions could occur when the streaming path is exercised.

StreamedSpan loses all pipeline metadata (is_cluster, transaction, commands) - `sentry_sdk/integrations/redis/utils.py:115-134`

In _set_pipeline_data, when the span is a StreamedSpan, the function builds the commands list (iterating through commands_seq) but never sets any attributes on the span. The is_cluster and is_transaction tags are skipped, and the redis.commands data is never converted to attributes. This results in pipeline spans with streaming enabled having no useful metadata, while regular Span instances retain all this information.


Duration: 2m 54s · Tokens: 915.9k in / 12.3k out · Cost: $1.46 (+extraction: $0.01, +merge: $0.00, +fix_gate: $0.00)

Annotations

Check warning on line 56 in sentry_sdk/integrations/redis/_sync_common.py

See this annotation in the file changed.

@sentry-warden sentry-warden / warden: code-review

Missing test coverage for new span streaming functionality

The PR introduces significant new functionality for span streaming support but the PR description explicitly indicates tests have not been added yet. This includes conditional logic for streaming spans in both `patch_redis_pipeline` and `patch_redis_client` functions. Without tests, regressions could occur when the streaming path is exercised.

Check warning on line 134 in sentry_sdk/integrations/redis/utils.py

See this annotation in the file changed.

@sentry-warden sentry-warden / warden: code-review

StreamedSpan loses all pipeline metadata (is_cluster, transaction, commands)

In `_set_pipeline_data`, when the span is a `StreamedSpan`, the function builds the `commands` list (iterating through `commands_seq`) but never sets any attributes on the span. The `is_cluster` and `is_transaction` tags are skipped, and the `redis.commands` data is never converted to attributes. This results in pipeline spans with streaming enabled having no useful metadata, while regular Span instances retain all this information.