dheerajturaga opened a new pull request, #68039:
URL: https://github.com/apache/airflow/pull/68039

   The Execution API trace-propagation dependency attaches an OpenTelemetry 
context before yielding and detaches it afterwards. When a client disconnects 
or the request is cancelled, the dependency generator is force-closed from a 
different asyncio task, so the detach ran against a contextvars.Token created 
in a different Context. OpenTelemetry caught and logged that ValueError at 
ERROR ("Failed to detach context") before our suppression could see it, 
producing alarming but harmless log noise on the Dag processor and other 
clients.
   
   Skip the detach on the GeneratorExit unwind path, where the originating 
Context is being discarded anyway, and detach only on normal completion.
   
   ---
   
   ##### Was generative AI tooling used to co-author this PR?
   
   <!--
   If generative AI tooling has been used in the process of authoring this PR, 
please
   change below checkbox to `[X]` followed by the name of the tool, uncomment 
the "Generated-by".
   -->
   
   - [ ] Yes (please specify the tool below)
   
   ClaudeCode Opus 4.8
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to