You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@airflow.apache.org by "AutomationDev85 (via GitHub)" <gi...@apache.org> on 2026/04/17 12:03:15 UTC
[PR] Fix DEFAULT_LOGGING_CONFIG use with right kwargs [airflow]
AutomationDev85 opened a new pull request, #65412:
URL: https://github.com/apache/airflow/pull/65412
# Overview
During testing for the Airflow 3.2.1 release, we found a logging configuration issue while setting up a Wasp remote logger.
The following error is raised at startup:
```
Unable to load the config, contains a configuration error.
Traceback (most recent call last):
File "/usr/python/lib/python3.12/logging/config.py", line 608, in configure
handler = self.configure_handler(handlers[name])
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/python/lib/python3.12/logging/config.py", line 876, in configure_handler
result = factory(**kwargs)
^^^^^^^^^^^^^^^^^
TypeError: FileTaskHandler.__init__() got an unexpected keyword argument 'remote_base'
```
After investigating the root cause we found that PR https://github.com/apache/airflow/pull/64832 introduced a new _handler_kwargs variable which "replace" the usage of the remote_task_handler_kwargs variable.
However, near the end of the file, DEFAULT_LOGGING_CONFIG is still initialized using remote_task_handler_kwargs instead of _handler_kwargs.
# Details of change:
* Initialize DEFAULT_LOGGING_CONFIG["handlers"]["task"] using the correct handler kwargs so the task handler receives matching parameters.
--
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: commits-unsubscribe@airflow.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [PR] Fix DEFAULT_LOGGING_CONFIG use right kwargs [airflow]
Posted by "github-actions[bot] (via GitHub)" <gi...@apache.org>.
github-actions[bot] commented on PR #65412:
URL: https://github.com/apache/airflow/pull/65412#issuecomment-4269550340
### Backport successfully created: v3-2-test
Note: As of [Merging PRs targeted for Airflow 3.X](https://github.com/apache/airflow/blob/main/dev/README_AIRFLOW3_DEV.md#merging-prs-targeted-for-airflow-3x)
the committer who merges the PR is responsible for backporting the PRs that are bug fixes (generally speaking) to the maintenance branches.
In matter of doubt please ask in [#release-management](https://apache-airflow.slack.com/archives/C03G9H97MM2) Slack channel.
<table>
<tr>
<th>Status</th>
<th>Branch</th>
<th>Result</th>
</tr>
<tr>
<td>✅</td>
<td>v3-2-test</td>
<td><a href="https://github.com/apache/airflow/pull/65424"><img src="https://img.shields.io/badge/PR-65424-blue" alt="PR Link"></a></td>
</tr>
</table>
--
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: commits-unsubscribe@airflow.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [PR] Fix DEFAULT_LOGGING_CONFIG use right kwargs [airflow]
Posted by "vatsrahul1001 (via GitHub)" <gi...@apache.org>.
vatsrahul1001 merged PR #65412:
URL: https://github.com/apache/airflow/pull/65412
--
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: commits-unsubscribe@airflow.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [PR] Fix DEFAULT_LOGGING_CONFIG use right kwargs [airflow]
Posted by "kaxil (via GitHub)" <gi...@apache.org>.
kaxil commented on code in PR #65412:
URL: https://github.com/apache/airflow/pull/65412#discussion_r3100371715
##########
airflow-core/src/airflow/config_templates/airflow_local_settings.py:
##########
@@ -370,4 +370,4 @@ def _default_conn_name_from(mod_path, hook_name):
"section 'elasticsearch' if you are using Elasticsearch. In the other case, "
"'remote_base_log_folder' option in the 'logging' section."
)
- DEFAULT_LOGGING_CONFIG["handlers"]["task"].update(remote_task_handler_kwargs)
+ DEFAULT_LOGGING_CONFIG["handlers"]["task"].update(_handler_kwargs)
Review Comment:
The fix looks correct and restores the pre-#64832 behavior. Two small follow-ups worth considering:
**1. Regression test.** The bug only triggers when `remote_logging=True` with a backend that resets `_handler_kwargs` (S3/Wasb/GCS/OSS/HDFS/CloudWatch), so it slipped through #64832. A parametrized test that reloads `airflow_local_settings` under each backend (with `mock.patch` on the `RemoteLogIO` import and `conf_vars` setting `remote_task_handler_kwargs` to a dict with `remote_base`/custom keys), then asserts the local `task` handler dict doesn't contain those keys, catches it in ~10s without needing real credentials. I validated it locally: fails on all six params without the fix, passes with it.
**2. Newsfragment.** No `65412.bugfix.rst` in this PR. Since this is a user-visible startup failure when remote logging is configured, it's worth a line in release notes.
--
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: commits-unsubscribe@airflow.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [PR] Fix DEFAULT_LOGGING_CONFIG use right kwargs [airflow]
Posted by "AutomationDev85 (via GitHub)" <gi...@apache.org>.
AutomationDev85 commented on code in PR #65412:
URL: https://github.com/apache/airflow/pull/65412#discussion_r3100732752
##########
airflow-core/src/airflow/config_templates/airflow_local_settings.py:
##########
@@ -370,4 +370,4 @@ def _default_conn_name_from(mod_path, hook_name):
"section 'elasticsearch' if you are using Elasticsearch. In the other case, "
"'remote_base_log_folder' option in the 'logging' section."
)
- DEFAULT_LOGGING_CONFIG["handlers"]["task"].update(remote_task_handler_kwargs)
+ DEFAULT_LOGGING_CONFIG["handlers"]["task"].update(_handler_kwargs)
Review Comment:
Thanks @kaxil , I add the unit test and used your proposal as a base.
--
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: commits-unsubscribe@airflow.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [PR] Fix DEFAULT_LOGGING_CONFIG use right kwargs [airflow]
Posted by "Copilot (via GitHub)" <gi...@apache.org>.
Copilot commented on code in PR #65412:
URL: https://github.com/apache/airflow/pull/65412#discussion_r3100270670
##########
airflow-core/src/airflow/config_templates/airflow_local_settings.py:
##########
@@ -370,4 +370,4 @@ def _default_conn_name_from(mod_path, hook_name):
"section 'elasticsearch' if you are using Elasticsearch. In the other case, "
"'remote_base_log_folder' option in the 'logging' section."
)
- DEFAULT_LOGGING_CONFIG["handlers"]["task"].update(remote_task_handler_kwargs)
+ DEFAULT_LOGGING_CONFIG["handlers"]["task"].update(_handler_kwargs)
Review Comment:
Consider adding a regression test that sets `logging.remote_logging=True`, uses a WASB `remote_base_log_folder`, and sets `logging.remote_task_handler_kwargs` containing keys like `remote_base`/`wasb_container`, then asserts `logging.config.dictConfig(DEFAULT_LOGGING_CONFIG)` (or `configure_logging()`) succeeds and that the instantiated `task` handler does not receive those RemoteLogIO-only kwargs. This would prevent reintroducing the startup `TypeError` this change fixes.
--
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: commits-unsubscribe@airflow.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [PR] Fix DEFAULT_LOGGING_CONFIG use right kwargs [airflow]
Posted by "kaxil (via GitHub)" <gi...@apache.org>.
kaxil commented on code in PR #65412:
URL: https://github.com/apache/airflow/pull/65412#discussion_r3100393541
##########
airflow-core/src/airflow/config_templates/airflow_local_settings.py:
##########
@@ -370,4 +370,4 @@ def _default_conn_name_from(mod_path, hook_name):
"section 'elasticsearch' if you are using Elasticsearch. In the other case, "
"'remote_base_log_folder' option in the 'logging' section."
)
- DEFAULT_LOGGING_CONFIG["handlers"]["task"].update(remote_task_handler_kwargs)
+ DEFAULT_LOGGING_CONFIG["handlers"]["task"].update(_handler_kwargs)
Review Comment:
Something like following in a new `airflow-core/tests/unit/config_templates/test_airflow_local_settings.py`:
```py
import importlib
import json
from unittest import mock
import pytest
from airflow.config_templates import airflow_local_settings
from tests_common.test_utils.config import conf_vars
@pytest.fixture
def restore_local_settings():
yield
importlib.reload(airflow_local_settings)
@pytest.mark.parametrize(
"remote_base, remote_io_path",
[
("s3://bucket/path",
"airflow.providers.amazon.aws.log.s3_task_handler.S3RemoteLogIO"),
("wasb-logs",
"airflow.providers.microsoft.azure.log.wasb_task_handler.WasbRemoteLogIO"),
("gs://bucket/path",
"airflow.providers.google.cloud.log.gcs_task_handler.GCSRemoteLogIO"),
("cloudwatch://arn:aws:logs:us-east-1:0:log-group:foo",
"airflow.providers.amazon.aws.log.cloudwatch_task_handler.CloudWatchRemoteLogIO"),
("oss://bucket/path",
"airflow.providers.alibaba.cloud.log.oss_task_handler.OSSRemoteLogIO"),
("hdfs://host/path",
"airflow.providers.apache.hdfs.log.hdfs_task_handler.HdfsRemoteLogIO"),
],
ids=["s3", "wasb", "gcs", "cloudwatch", "oss", "hdfs"],
)
def test_remote_task_handler_kwargs_not_leaked_to_local_task_handler(
remote_base, remote_io_path, restore_local_settings
):
"""Regression for apache/airflow#65412: remote_task_handler_kwargs must be consumed
by the RemoteLogIO for the backend, not re-applied to the local FileTaskHandler."""
user_kwargs = {"remote_base": "ignored", "custom_key": "v"}
with mock.patch(remote_io_path), conf_vars(
{
("logging", "remote_logging"): "True",
("logging", "remote_base_log_folder"): remote_base,
("logging", "remote_task_handler_kwargs"): json.dumps(user_kwargs),
}
):
importlib.reload(airflow_local_settings)
task_cfg = airflow_local_settings.DEFAULT_LOGGING_CONFIG["handlers"]["task"]
for k in user_kwargs:
assert k not in task_cfg, f"{k!r} leaked into task handler for {remote_base}"
```
--
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: commits-unsubscribe@airflow.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [PR] Fix DEFAULT_LOGGING_CONFIG use right kwargs [airflow]
Posted by "github-actions[bot] (via GitHub)" <gi...@apache.org>.
github-actions[bot] commented on PR #65412:
URL: https://github.com/apache/airflow/pull/65412#issuecomment-4269548425
Hi maintainer, this PR was merged without a milestone set.
We've automatically set the milestone to **[Airflow 3.2.2](https://github.com/apache/airflow/milestone/138)** based on: backport label targeting v3-2-test
If this milestone is not correct, please update it to the appropriate milestone.
> This comment was generated by [Milestone Tag Assistant](https://github.com/apache/airflow/blob/main/.github/workflows/milestone-tag-assistant.yml).
--
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: commits-unsubscribe@airflow.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [PR] Fix DEFAULT_LOGGING_CONFIG use right kwargs [airflow]
Posted by "kaxil (via GitHub)" <gi...@apache.org>.
kaxil commented on code in PR #65412:
URL: https://github.com/apache/airflow/pull/65412#discussion_r3100393541
##########
airflow-core/src/airflow/config_templates/airflow_local_settings.py:
##########
@@ -370,4 +370,4 @@ def _default_conn_name_from(mod_path, hook_name):
"section 'elasticsearch' if you are using Elasticsearch. In the other case, "
"'remote_base_log_folder' option in the 'logging' section."
)
- DEFAULT_LOGGING_CONFIG["handlers"]["task"].update(remote_task_handler_kwargs)
+ DEFAULT_LOGGING_CONFIG["handlers"]["task"].update(_handler_kwargs)
Review Comment:
Something like following in a new `airflow-core/tests/unit/config_templates/test_airflow_local_settings.py`:
```py
import importlib
import json
from unittest import mock
import pytest
from airflow.config_templates import airflow_local_settings
from tests_common.test_utils.config import conf_vars
@pytest.fixture
def restore_local_settings():
yield
importlib.reload(airflow_local_settings)
@pytest.mark.parametrize(
"remote_base, remote_io_path",
[
("s3://bucket/path",
"airflow.providers.amazon.aws.log.s3_task_handler.S3RemoteLogIO"),
("wasb-logs",
"airflow.providers.microsoft.azure.log.wasb_task_handler.WasbRemoteLogIO"),
("gs://bucket/path",
"airflow.providers.google.cloud.log.gcs_task_handler.GCSRemoteLogIO"),
("cloudwatch://arn:aws:logs:us-east-1:0:log-group:foo",
"airflow.providers.amazon.aws.log.cloudwatch_task_handler.CloudWatchRemoteLogIO"),
("oss://bucket/path",
"airflow.providers.alibaba.cloud.log.oss_task_handler.OSSRemoteLogIO"),
("hdfs://host/path",
"airflow.providers.apache.hdfs.log.hdfs_task_handler.HdfsRemoteLogIO"),
],
ids=["s3", "wasb", "gcs", "cloudwatch", "oss", "hdfs"],
)
def test_remote_task_handler_kwargs_not_leaked_to_local_task_handler(
remote_base, remote_io_path, restore_local_settings
):
"""Regression for apache/airflow#65412: remote_task_handler_kwargs must be consumed
by the RemoteLogIO for the backend, not re-applied to the local FileTaskHandler."""
user_kwargs = {"remote_base": "ignored", "custom_key": "v"}
with mock.patch(remote_io_path), conf_vars(
{
("logging", "remote_logging"): "True",
("logging", "remote_base_log_folder"): remote_base,
("logging", "remote_task_handler_kwargs"): json.dumps(user_kwargs),
}
):
importlib.reload(airflow_local_settings)
task_cfg = airflow_local_settings.DEFAULT_LOGGING_CONFIG["handlers"]["task"]
for k in user_kwargs:
assert k not in task_cfg, f"{k!r} leaked into task handler for {remote_base}"
Why this shape:
```
--
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: commits-unsubscribe@airflow.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [PR] Fix DEFAULT_LOGGING_CONFIG use right kwargs [airflow]
Posted by "kaxil (via GitHub)" <gi...@apache.org>.
kaxil commented on code in PR #65412:
URL: https://github.com/apache/airflow/pull/65412#discussion_r3100393541
##########
airflow-core/src/airflow/config_templates/airflow_local_settings.py:
##########
@@ -370,4 +370,4 @@ def _default_conn_name_from(mod_path, hook_name):
"section 'elasticsearch' if you are using Elasticsearch. In the other case, "
"'remote_base_log_folder' option in the 'logging' section."
)
- DEFAULT_LOGGING_CONFIG["handlers"]["task"].update(remote_task_handler_kwargs)
+ DEFAULT_LOGGING_CONFIG["handlers"]["task"].update(_handler_kwargs)
Review Comment:
Something like following in a new `airflow-core/tests/unit/config_templates/test_airflow_local_settings.py`:
```py
import importlib
import json
from unittest import mock
import pytest
from airflow.config_templates import airflow_local_settings
from tests_common.test_utils.config import conf_vars
@pytest.fixture
def restore_local_settings():
yield
importlib.reload(airflow_local_settings)
@pytest.mark.parametrize(
"remote_base, remote_io_path",
[
("s3://bucket/path",
"airflow.providers.amazon.aws.log.s3_task_handler.S3RemoteLogIO"),
("wasb-logs",
"airflow.providers.microsoft.azure.log.wasb_task_handler.WasbRemoteLogIO"),
("gs://bucket/path",
"airflow.providers.google.cloud.log.gcs_task_handler.GCSRemoteLogIO"),
("cloudwatch://arn:aws:logs:us-east-1:0:log-group:foo",
"airflow.providers.amazon.aws.log.cloudwatch_task_handler.CloudWatchRemoteLogIO"),
("oss://bucket/path",
"airflow.providers.alibaba.cloud.log.oss_task_handler.OSSRemoteLogIO"),
("hdfs://host/path",
"airflow.providers.apache.hdfs.log.hdfs_task_handler.HdfsRemoteLogIO"),
],
ids=["s3", "wasb", "gcs", "cloudwatch", "oss", "hdfs"],
)
def test_remote_task_handler_kwargs_not_leaked_to_local_task_handler(
remote_base, remote_io_path, restore_local_settings
):
"""Regression for apache/airflow#65412: remote_task_handler_kwargs must be consumed
by the RemoteLogIO for the backend, not re-applied to the local FileTaskHandler."""
user_kwargs = {"remote_base": "ignored", "custom_key": "v"}
with mock.patch(remote_io_path), conf_vars(
{
("logging", "remote_logging"): "True",
("logging", "remote_base_log_folder"): remote_base,
("logging", "remote_task_handler_kwargs"): json.dumps(user_kwargs),
}
):
importlib.reload(airflow_local_settings)
task_cfg = airflow_local_settings.DEFAULT_LOGGING_CONFIG["handlers"]["task"]
for k in user_kwargs:
assert k not in task_cfg, f"{k!r} leaked into task handler for {remote_base}"
Why this shape:
```
--
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: commits-unsubscribe@airflow.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [PR] Fix DEFAULT_LOGGING_CONFIG use right kwargs [airflow]
Posted by "kaxil (via GitHub)" <gi...@apache.org>.
kaxil commented on code in PR #65412:
URL: https://github.com/apache/airflow/pull/65412#discussion_r3100393541
##########
airflow-core/src/airflow/config_templates/airflow_local_settings.py:
##########
@@ -370,4 +370,4 @@ def _default_conn_name_from(mod_path, hook_name):
"section 'elasticsearch' if you are using Elasticsearch. In the other case, "
"'remote_base_log_folder' option in the 'logging' section."
)
- DEFAULT_LOGGING_CONFIG["handlers"]["task"].update(remote_task_handler_kwargs)
+ DEFAULT_LOGGING_CONFIG["handlers"]["task"].update(_handler_kwargs)
Review Comment:
import importlib
import json
from unittest import mock
import pytest
from airflow.config_templates import airflow_local_settings
from tests_common.test_utils.config import conf_vars
@pytest.fixture
def restore_local_settings():
yield
importlib.reload(airflow_local_settings)
@pytest.mark.parametrize(
"remote_base, remote_io_path",
[
("s3://bucket/path",
"airflow.providers.amazon.aws.log.s3_task_handler.S3RemoteLogIO"),
("wasb-logs",
"airflow.providers.microsoft.azure.log.wasb_task_handler.WasbRemoteLogIO"),
("gs://bucket/path",
"airflow.providers.google.cloud.log.gcs_task_handler.GCSRemoteLogIO"),
("cloudwatch://arn:aws:logs:us-east-1:0:log-group:foo",
"airflow.providers.amazon.aws.log.cloudwatch_task_handler.CloudWatchRemoteLogIO"),
("oss://bucket/path",
"airflow.providers.alibaba.cloud.log.oss_task_handler.OSSRemoteLogIO"),
("hdfs://host/path",
"airflow.providers.apache.hdfs.log.hdfs_task_handler.HdfsRemoteLogIO"),
],
ids=["s3", "wasb", "gcs", "cloudwatch", "oss", "hdfs"],
)
def test_remote_task_handler_kwargs_not_leaked_to_local_task_handler(
remote_base, remote_io_path, restore_local_settings
):
"""Regression for apache/airflow#65412: remote_task_handler_kwargs must be consumed
by the RemoteLogIO for the backend, not re-applied to the local FileTaskHandler."""
user_kwargs = {"remote_base": "ignored", "custom_key": "v"}
with mock.patch(remote_io_path), conf_vars(
{
("logging", "remote_logging"): "True",
("logging", "remote_base_log_folder"): remote_base,
("logging", "remote_task_handler_kwargs"): json.dumps(user_kwargs),
}
):
importlib.reload(airflow_local_settings)
task_cfg = airflow_local_settings.DEFAULT_LOGGING_CONFIG["handlers"]["task"]
for k in user_kwargs:
assert k not in task_cfg, f"{k!r} leaked into task handler for {remote_base}"
--
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: commits-unsubscribe@airflow.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [PR] Fix DEFAULT_LOGGING_CONFIG use right kwargs [airflow]
Posted by "kaxil (via GitHub)" <gi...@apache.org>.
kaxil commented on code in PR #65412:
URL: https://github.com/apache/airflow/pull/65412#discussion_r3100371715
##########
airflow-core/src/airflow/config_templates/airflow_local_settings.py:
##########
@@ -370,4 +370,4 @@ def _default_conn_name_from(mod_path, hook_name):
"section 'elasticsearch' if you are using Elasticsearch. In the other case, "
"'remote_base_log_folder' option in the 'logging' section."
)
- DEFAULT_LOGGING_CONFIG["handlers"]["task"].update(remote_task_handler_kwargs)
+ DEFAULT_LOGGING_CONFIG["handlers"]["task"].update(_handler_kwargs)
Review Comment:
The fix looks correct and restores the pre-#64832 behavior. Two small follow-ups worth considering:
**1. Regression test.** The bug only triggers when `remote_logging=True` with a backend that resets `_handler_kwargs` (S3/Wasb/GCS/OSS/HDFS/CloudWatch), so it slipped through #64832. A parametrized test that reloads `airflow_local_settings` under each backend (with `mock.patch` on the `RemoteLogIO` import and `conf_vars` setting `remote_task_handler_kwargs` to a dict with `remote_base`/custom keys), then asserts the local `task` handler dict doesn't contain those keys, catches it in ~10s without needing real credentials. I validated it locally: fails on all six params without the fix, passes with it.
--
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: commits-unsubscribe@airflow.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [PR] Fix DEFAULT_LOGGING_CONFIG use right kwargs [airflow]
Posted by "kaxil (via GitHub)" <gi...@apache.org>.
kaxil commented on code in PR #65412:
URL: https://github.com/apache/airflow/pull/65412#discussion_r3100371715
##########
airflow-core/src/airflow/config_templates/airflow_local_settings.py:
##########
@@ -370,4 +370,4 @@ def _default_conn_name_from(mod_path, hook_name):
"section 'elasticsearch' if you are using Elasticsearch. In the other case, "
"'remote_base_log_folder' option in the 'logging' section."
)
- DEFAULT_LOGGING_CONFIG["handlers"]["task"].update(remote_task_handler_kwargs)
+ DEFAULT_LOGGING_CONFIG["handlers"]["task"].update(_handler_kwargs)
Review Comment:
The fix looks correct and restores the pre-#64832 behavior. Two small follow-ups worth considering:
**1. Regression test.** The bug only triggers when `remote_logging=True` with a backend that resets `_handler_kwargs` (S3/Wasb/GCS/OSS/HDFS/CloudWatch), so it slipped through #64832. A parametrized test that reloads `airflow_local_settings` under each backend (with `mock.patch` on the `RemoteLogIO` import and `conf_vars` setting `remote_task_handler_kwargs` to a dict with `remote_base`/custom keys), then asserts the local `task` handler dict doesn't contain those keys, catches it in ~10s without needing real credentials. I validated it locally: fails on all six params without the fix, passes with it.
--
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: commits-unsubscribe@airflow.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org