Repository navigation
Conversation
Pull request dashboard statusWaiting on reviewers · refreshed 2026-10-29 19:08 UTC Review the latest changes. Status above doesn't look right?
|
lmolkova
force-pushed
the
lmolkova/openai-v2-cleanup
branch
from
October 29, 2026 17:28
c191946 to
3e4ec33
Compare
7 tasks done
lmolkova
force-pushed
the
lmolkova/openai-v2-cleanup
branch
from
October 29, 2026 17:34
3e4ec33 to
c35bd9d
Compare
lmolkova
force-pushed
the
lmolkova/openai-v2-cleanup
branch
from
October 29, 2026 17:42
c35bd9d to
9d0e661
Compare
Contributor
There was a problem hiding this comment.
🟢 Approval recommended
No active review issues remain for the cleanup of unused experimental OpenAI instrumentation.
No open issues 🎉
What changed in this PR
Removes unused built-in experimental OpenAI instrumentation following #5260’s disablement and #5261’s delegation to opentelemetry-instrumentation-genai-openai. This cleanup is intended to preserve existing runtime behavior.
Changes:
- Deletes experimental chat stream wrappers, Responses API modules, and associated tests and recordings.
- Simplifies legacy instrumentation helpers, test assertions, and fixtures by removing experimental-mode branches and parameters.
- Removes changelog fragments for the deleted implementation.
All paths below are relative to instrumentation-genai/opentelemetry-instrumentation-openai-v2/.
| File | Description |
|---|---|
tests/test_utils.py |
Removes experimental helpers and simplifies legacy assertions. |
tests/test_responses.py |
Deletes obsolete Responses API integration tests. |
tests/test_response_wrappers.py |
Deletes tests for removed response wrappers. |
tests/test_response_extractors.py |
Deletes tests for removed response extractors. |
tests/test_request_attributes.py |
Removes experimental parameters and test case. |
tests/test_embeddings.py |
Simplifies synchronous embedding assertions. |
tests/test_completion_hook.py |
Deletes skipped built-in completion-hook tests. |
tests/test_chat_metrics.py |
Uses legacy metric attributes directly. |
tests/test_async_embeddings.py |
Simplifies asynchronous embedding assertions. |
tests/conftest.py |
Consolidates legacy fixtures and removes experimental modes. |
tests/cassettes/test_responses_stream_wrapper_finalize_idempotent[content_mode0].yaml |
Deletes finalization recording. |
tests/cassettes/test_responses_create_with_content_span_unsampled[content_mode0].yaml |
Deletes unsampled-content recording. |
tests/cassettes/test_responses_create_with_content_shapes[content_mode0].yaml |
Deletes message-shape recording. |
tests/cassettes/test_responses_create_with_all_params[content_mode0].yaml |
Deletes request-parameter recording. |
tests/cassettes/test_responses_create_token_usage[content_mode0].yaml |
Deletes token-usage recording. |
tests/cassettes/test_responses_create_streaming[content_mode0].yaml |
Deletes basic streaming recording. |
tests/cassettes/test_responses_create_streaming_user_exception[content_mode0].yaml |
Deletes user-exception recording. |
tests/cassettes/test_responses_create_streaming_iteration[content_mode0].yaml |
Deletes stream-iteration recording. |
tests/cassettes/test_responses_create_streaming_delegates_response_attribute[content_mode0].yaml |
Deletes response-delegation recording. |
tests/cassettes/test_responses_create_streaming_captures_content[content_mode0].yaml |
Deletes streaming-content recording. |
tests/cassettes/test_responses_create_streaming_aggregates_cache_tokens[content_mode0].yaml |
Deletes streaming cache-token recording. |
tests/cassettes/test_responses_create_stream_propagation_error[content_mode0].yaml |
Deletes stream-error recording. |
tests/cassettes/test_responses_create_stop_reason[content_mode0].yaml |
Deletes stop-reason recording. |
tests/cassettes/test_responses_create_reports_reasoning_tokens[content_mode0].yaml |
Deletes reasoning-token recording. |
tests/cassettes/test_responses_create_instrumentation_error_swallowed[content_mode0].yaml |
Deletes instrumentation-error recording. |
tests/cassettes/test_responses_create_event_only_no_content_in_span.yaml |
Deletes event-only recording. |
tests/cassettes/test_responses_create_captures_tool_call_content[content_mode0].yaml |
Deletes tool-call content recording. |
tests/cassettes/test_responses_create_captures_content[content_mode0].yaml |
Deletes content-capture recording. |
tests/cassettes/test_responses_create_basic[content_mode0].yaml |
Deletes basic response recording. |
tests/cassettes/test_responses_create_api_error[content_mode0].yaml |
Deletes API-error recording. |
tests/cassettes/test_responses_create_aggregates_cache_tokens[content_mode0].yaml |
Deletes cache-token recording. |
src/opentelemetry/instrumentation/openai_v2/utils.py |
Removes experimental attribute branches and unused helpers. |
src/opentelemetry/instrumentation/openai_v2/response_wrappers.py |
Deletes experimental response stream wrappers. |
src/opentelemetry/instrumentation/openai_v2/response_extractors.py |
Deletes experimental response extraction logic. |
src/opentelemetry/instrumentation/openai_v2/patch.py |
Removes experimental flags from wrapper signatures and calls. |
src/opentelemetry/instrumentation/openai_v2/patch_responses.py |
Deletes built-in Responses API patching. |
src/opentelemetry/instrumentation/openai_v2/chat_wrappers.py |
Deletes experimental chat stream wrappers. |
src/opentelemetry/instrumentation/openai_v2/__init__.py |
Updates embedding wrapper calls to simplified signatures. |
.changelog/4554.changed |
Removes experimental tool-definition changelog fragment. |
.changelog/4500.changed |
Removes experimental stream-refactor changelog fragment. |
Review effort: Balanced
lmolkova
force-pushed
the
lmolkova/openai-v2-cleanup
branch
from
October 29, 2026 18:00
ad87afb to
0d54ee6
Compare
Removes the built-in latest experimental implementation that is no longer wired up, its tests and recordings, the experimental branches in the remaining tests, and changelog entries for the removed code. No functional changes.
lmolkova
force-pushed
the
lmolkova/openai-v2-cleanup
branch
from
October 29, 2026 18:59
0d54ee6 to
7c55418
Compare
lmolkova
marked this pull request as ready for review
October 29, 2026 19:08
This branch has not been deployed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Removes code that became unused once the built-in latest experimental implementation was turned off in #5260. No functional changes.
Falselatest_experimental_enabledparameters.Type of change
Checklist:
See contributing.md for styleguide, changelog guidelines, and more.
tox -e precommittox -e typecheck