pankajkoti commented on code in PR #43183:
URL: https://github.com/apache/airflow/pull/43183#discussion_r1807132581
##########
airflow/utils/log/file_task_handler.py:
##########
@@ -238,10 +237,6 @@ def set_context(self, ti: TaskInstance, *, identifier: str
| None = None) -> Non
self.handler.setLevel(self.level)
return SetContextPropagate.MAINTAIN_PROPAGATE if
self.maintain_propagate else None
- @cached_property
- def supports_task_context_logging(self) -> bool:
- return "identifier" in inspect.signature(self.set_context).parameters
Review Comment:
Do we intend to keep accepting the `identifier` param in the `set_context`
method above that we had introduced in
https://github.com/apache/airflow/pull/32646/files. The docstring for that
param in the method is currently tightly related to the task context logger.
This param was also extended to be used in the `set_context` method of the
provider log handlers with the below PRs
1. AWS S3: https://github.com/apache/airflow/pull/32950
2. GCP GCS: https://github.com/apache/airflow/pull/32970
3. Azure WASB: https://github.com/apache/airflow/pull/32972
4. ElasticSearch: https://github.com/apache/airflow/pull/32977
It seems the conditionals around AF versions in those provider PRs were
removed & cleaned up when those providers started having Airflow min version as
2.8 -- in PR https://github.com/apache/airflow/pull/42764
If we decide to drop the param, perhaps would also be a good idea to add a
TODO in those providers saying that this param would no longer be needed/used
when min AF version is 3.0 & can be cleaned up.
--
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]