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

   - depends on: https://github.com/apache/airflow/pull/67104
   - related: https://github.com/apache/airflow/issues/65281
   
   ## Why
   
   ``OpensearchTaskHandler.__init__`` papers over a missing ``REMOTE_TASK_LOG`` 
in the user's ``[logging] logging_config_class`` module by self-registering as 
the remote task-log reader during ``dictConfig``. That side-effect was the only 
thing keeping UI log read-back working for users who had swapped in the OS 
handler via a custom logging config, and it hides the real contract 
(``REMOTE_TASK_LOG`` must be set at module scope) that the core PR (#67104) 
documents.
   
   ## How
   
   - Emit ``AirflowProviderDeprecationWarning`` from the implicit-registration 
branch in ``OpensearchTaskHandler.__init__``, with ``stacklevel=1`` so 
module-based deprecation filters still match through ``dictConfig``.
   - Update the OpenSearch logging guide 
(``providers/opensearch/docs/logging/index.rst``) to set ``REMOTE_TASK_LOG = 
OpensearchRemoteLogIO(...)`` at module scope in the user's 
``logging_config_class`` module instead of relying on the deprecated 
self-registration.
   - Add a provider-local ``conftest.py`` that suppresses the new deprecation 
warning during direct handler construction in unit tests — this mirrors the 
recommended user pattern (``REMOTE_TASK_LOG`` set at module scope) so the 
forbidden-warnings plugin does not flag handler instantiation in tests.
   - Add a changelog entry announcing the deprecation.
   
   ---
   
   ##### Was generative AI tooling used to co-author this PR?
   
   - [x] Yes, with help of Claude Code Opus 4.7 following [the 
guidelines](https://github.com/apache/airflow/blob/main/contributing-docs/05_pull_requests.rst#gen-ai-assisted-contributions)


-- 
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