Skip to content

Expose basic Otel classes and funtions to be importable through redis.observability to match the examples in the readthedocs#3996

Merged
petyaslavova merged 3 commits intomasterfrom
ps_fix_otel_init_py_to_expose_base_objects
Mar 16, 2026
Merged

Expose basic Otel classes and funtions to be importable through redis.observability to match the examples in the readthedocs#3996
petyaslavova merged 3 commits intomasterfrom
ps_fix_otel_init_py_to_expose_base_objects

Conversation

@petyaslavova
Copy link
Copy Markdown
Collaborator

@petyaslavova petyaslavova commented Mar 10, 2026

Fixes #3992


Note

Low Risk
Low risk: this only adds a public re-export surface (__init__.py) plus tests, with no changes to runtime observability behavior.

Overview
redis.observability is turned into a documented public entrypoint by re-exporting core OpenTelemetry-facing types and helpers (OTelConfig, MetricGroup, TelemetryOption, and the get/reset_observability_instance APIs) via __all__.

Adds unit tests to ensure these symbols are correctly re-exported and accessible, preventing future regressions in the public import paths used by the docs.

Written by Cursor Bugbot for commit 86656b3. This will update automatically on new commits. Configure here.

@jit-ci
Copy link
Copy Markdown

jit-ci Bot commented Mar 10, 2026

🛡️ Jit Security Scan Results

CRITICAL HIGH MEDIUM

✅ No security findings were detected in this PR


Security scan by Jit

Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Adds a package initializer for redis.observability so the OpenTelemetry observability API can be imported from the package root, matching the ReadTheDocs examples and addressing #3992.

Changes:

  • Introduces redis/observability/__init__.py to re-export key observability symbols (OTelConfig, MetricGroup, TelemetryOption, ObservabilityInstance, get_observability_instance, reset_observability_instance).
  • Adds basic usage documentation in the module docstring.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread redis/observability/__init__.py
@petyaslavova petyaslavova force-pushed the ps_fix_otel_init_py_to_expose_base_objects branch from dd198d1 to cc8e3c4 Compare March 10, 2026 12:44
….observability to match the examples in the readthedocs
@petyaslavova petyaslavova force-pushed the ps_fix_otel_init_py_to_expose_base_objects branch from cc8e3c4 to b8a70d1 Compare March 10, 2026 12:45
@petyaslavova petyaslavova merged commit 7465249 into master Mar 16, 2026
178 of 180 checks passed
@petyaslavova petyaslavova deleted the ps_fix_otel_init_py_to_expose_base_objects branch March 16, 2026 14:07
petyaslavova added a commit that referenced this pull request Mar 23, 2026
….observability to match the examples in the readthedocs (#3996)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Invalid imports are present in the OpenTelemetry usage documentation

3 participants