korex-f commented on code in PR #66633:
URL: https://github.com/apache/airflow/pull/66633#discussion_r3629026471
##########
task-sdk/src/airflow/sdk/log.py:
##########
@@ -133,6 +139,15 @@ def configure_logging(
callsite_parameters=callsite_params,
)
+ # dictConfig has now run — safe to build the watchtower handler.
+ # We append remote processors into the already-configured structlog chain,
+ # inserting before the final renderer (last processor in the chain).
+ if (remote := load_remote_log_handler()) and (remote_processors :=
getattr(remote, "processors")):
+ current_processors = list(structlog.get_config()["processors"])
+ # Insert before the final renderer
+ updated_processors = current_processors[:-1] + list(remote_processors)
+ [current_processors[-1]]
+ structlog.configure(processors=updated_processors)
Review Comment:
Done. Thanks
--
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]