Skip to content

AI-18: Move set_tracing_disabled from workflow to worker startup#288

Open
xumaple wants to merge 3 commits intomainfrom
maplexu/AI-18-move-set-tracing-disabled
Open

AI-18: Move set_tracing_disabled from workflow to worker startup#288
xumaple wants to merge 3 commits intomainfrom
maplexu/AI-18-move-set-tracing-disabled

Conversation

@xumaple
Copy link
Copy Markdown

@xumaple xumaple commented Apr 10, 2026

Summary

  • Moved set_tracing_disabled(disabled=True) out of workflow run() methods and into worker main() functions in the openai_agents/model_providers/ samples
  • set_tracing_disabled is a global side effect that shouldn't live inside deterministic workflow code — it belongs at worker startup where it runs once per process

Fixes #243

set_tracing_disabled is a global side effect that shouldn't be called
inside deterministic workflow code. Move it to the top of main() in the
worker files where it runs once at process startup.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
@xumaple xumaple requested a review from a team as a code owner April 10, 2026 19:00
xumaple and others added 2 commits April 10, 2026 15:17
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Copy link
Copy Markdown

@DABH DABH left a comment

Choose a reason for hiding this comment

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

Yep, this does exactly what #243 suggests. Thanks for the fix and for the comments that explain why set_tracing_disabled is now being called in the right place.

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.

[Bug] Remove/move set_tracing_disabled from inside OpenAI sample workflows

2 participants