[PR] feature: callable for template_fields [airflow]

2024-01-26 Thread via GitHub
raphaelauv opened a new pull request, #37028: URL: https://github.com/apache/airflow/pull/37028 following discussion of https://github.com/apache/airflow/pull/35844 -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the U

Re: [PR] feature: callable for template_fields [airflow]

2024-03-26 Thread via GitHub
uranusjr commented on PR #37028: URL: https://github.com/apache/airflow/pull/37028#issuecomment-2021595841 Yeah after some more thought I really do not like the fact that the return value gets treated as a template string. The callable should just return the rendered value instead. This is

Re: [PR] feature: callable for template_fields [airflow]

2024-03-15 Thread via GitHub
github-actions[bot] commented on PR #37028: URL: https://github.com/apache/airflow/pull/37028#issuecomment-2000733462 This pull request has been automatically marked as stale because it has not had recent activity. It will be closed in 5 days if no further activity occurs. Thank you for you

Re: [PR] feature: callable for template_fields [airflow]

2024-01-30 Thread via GitHub
uranusjr commented on PR #37028: URL: https://github.com/apache/airflow/pull/37028#issuecomment-1917484651 I wonder if we should turn the return value of the callable into a template and render that. Since a callable can do whatever it wants, supporting returning a template seems redundant

Re: [PR] feature: callable for template_fields [airflow]

2024-05-22 Thread via GitHub
github-actions[bot] commented on PR #37028: URL: https://github.com/apache/airflow/pull/37028#issuecomment-2126272127 This pull request has been automatically marked as stale because it has not had recent activity. It will be closed in 5 days if no further activity occurs. Thank you for you

Re: [PR] feature: callable for template_fields [airflow]

2024-05-27 Thread via GitHub
raphaelauv commented on PR #37028: URL: https://github.com/apache/airflow/pull/37028#issuecomment-2133076882 no stale -- 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 uns

Re: [PR] feature: callable for template_fields [airflow]

2024-05-30 Thread via GitHub
raphaelauv commented on PR #37028: URL: https://github.com/apache/airflow/pull/37028#issuecomment-2139847302 @uranusjr thanks for your review , wdyt of this second implementation ? -- This is an automated message from the Apache Git Service. To respond to the message, please log on to Git

Re: [PR] feature: callable for template_fields [airflow]

2024-05-30 Thread via GitHub
eladkal commented on code in PR #37028: URL: https://github.com/apache/airflow/pull/37028#discussion_r1620928073 ## airflow/providers/amazon/aws/transfers/dynamodb_to_s3.py: ## @@ -105,7 +105,6 @@ class DynamoDBToS3Operator(AwsToAwsBaseOperator): "file_size", "

Re: [PR] feature: callable for template_fields [airflow]

2024-05-30 Thread via GitHub
raphaelauv commented on code in PR #37028: URL: https://github.com/apache/airflow/pull/37028#discussion_r1620969489 ## airflow/providers/amazon/aws/transfers/dynamodb_to_s3.py: ## @@ -105,7 +105,6 @@ class DynamoDBToS3Operator(AwsToAwsBaseOperator): "file_size",

Re: [PR] feature: callable for template_fields [airflow]

2024-05-30 Thread via GitHub
raphaelauv commented on code in PR #37028: URL: https://github.com/apache/airflow/pull/37028#discussion_r1620969489 ## airflow/providers/amazon/aws/transfers/dynamodb_to_s3.py: ## @@ -105,7 +105,6 @@ class DynamoDBToS3Operator(AwsToAwsBaseOperator): "file_size",

Re: [PR] feature: callable for template_fields [airflow]

2024-05-30 Thread via GitHub
eladkal commented on code in PR #37028: URL: https://github.com/apache/airflow/pull/37028#discussion_r1620974798 ## airflow/providers/amazon/aws/transfers/dynamodb_to_s3.py: ## @@ -105,7 +105,6 @@ class DynamoDBToS3Operator(AwsToAwsBaseOperator): "file_size", "

Re: [PR] feature: callable for template_fields [airflow]

2024-05-30 Thread via GitHub
raphaelauv commented on code in PR #37028: URL: https://github.com/apache/airflow/pull/37028#discussion_r1620989140 ## airflow/providers/amazon/aws/transfers/dynamodb_to_s3.py: ## @@ -105,7 +105,6 @@ class DynamoDBToS3Operator(AwsToAwsBaseOperator): "file_size",

Re: [PR] feature: callable for template_fields [airflow]

2024-06-02 Thread via GitHub
uranusjr commented on PR #37028: URL: https://github.com/apache/airflow/pull/37028#issuecomment-2144241883 The idea looks fine to me, but this should be a part of `_do_render_template_fields` instead, or even somewhere deeper in the call chain. `render_template_fields` is an override point

Re: [PR] feature: callable for template_fields [airflow]

2024-06-03 Thread via GitHub
raphaelauv commented on PR #37028: URL: https://github.com/apache/airflow/pull/37028#issuecomment-2146017353 @uranusjr thanks again, I did the change -- 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

Re: [PR] feature: callable for template_fields [airflow]

2024-06-03 Thread via GitHub
uranusjr commented on code in PR #37028: URL: https://github.com/apache/airflow/pull/37028#discussion_r1625212311 ## airflow/models/abstractoperator.py: ## @@ -730,12 +740,15 @@ def _do_render_template_fields( pass try: -rendered_c

Re: [PR] feature: callable for template_fields [airflow]

2024-06-03 Thread via GitHub
uranusjr commented on PR #37028: URL: https://github.com/apache/airflow/pull/37028#issuecomment-2146386357 Also we need documentation on this. -- 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

Re: [PR] feature: callable for template_fields [airflow]

2024-06-04 Thread via GitHub
raphaelauv commented on PR #37028: URL: https://github.com/apache/airflow/pull/37028#issuecomment-2146889155 > Also we need documentation on this. yeah I will when we find the final implementation -- This is an automated message from the Apache Git Service. To respond to the message

Re: [PR] feature: callable for template_fields [airflow]

2024-06-04 Thread via GitHub
raphaelauv commented on code in PR #37028: URL: https://github.com/apache/airflow/pull/37028#discussion_r1625559965 ## airflow/models/abstractoperator.py: ## @@ -730,12 +740,15 @@ def _do_render_template_fields( pass try: -rendered

Re: [PR] feature: callable for template_fields [airflow]

2024-06-04 Thread via GitHub
uranusjr commented on code in PR #37028: URL: https://github.com/apache/airflow/pull/37028#discussion_r1625654355 ## airflow/models/baseoperator.py: ## @@ -1354,7 +1354,7 @@ def render_template_fields( context: Context, jinja_env: jinja2.Environment | None = No

Re: [PR] feature: callable for template_fields [airflow]

2024-06-04 Thread via GitHub
uranusjr commented on code in PR #37028: URL: https://github.com/apache/airflow/pull/37028#discussion_r1625658753 ## airflow/models/abstractoperator.py: ## @@ -730,12 +733,15 @@ def _do_render_template_fields( pass try: -rendered_c

Re: [PR] feature: callable for template_fields [airflow]

2024-06-04 Thread via GitHub
uranusjr commented on code in PR #37028: URL: https://github.com/apache/airflow/pull/37028#discussion_r1625658753 ## airflow/models/abstractoperator.py: ## @@ -730,12 +733,15 @@ def _do_render_template_fields( pass try: -rendered_c

Re: [PR] feature: callable for template_fields [airflow]

2024-06-04 Thread via GitHub
uranusjr commented on code in PR #37028: URL: https://github.com/apache/airflow/pull/37028#discussion_r1625748411 ## airflow/models/abstractoperator.py: ## @@ -696,6 +696,9 @@ def get_template_env(self, dag: DAG | None = None) -> jinja2.Environment: dag = self.get_

Re: [PR] feature: callable for template_fields [airflow]

2024-06-04 Thread via GitHub
uranusjr commented on PR #37028: URL: https://github.com/apache/airflow/pull/37028#issuecomment-2147169337 Design looks good now to me. -- 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 specifi

Re: [PR] feature: callable for template_fields [airflow]

2024-06-04 Thread via GitHub
raphaelauv commented on code in PR #37028: URL: https://github.com/apache/airflow/pull/37028#discussion_r1625835995 ## airflow/models/abstractoperator.py: ## @@ -696,6 +696,9 @@ def get_template_env(self, dag: DAG | None = None) -> jinja2.Environment: dag = self.ge

Re: [PR] feature: callable for template_fields [airflow]

2024-06-05 Thread via GitHub
raphaelauv commented on PR #37028: URL: https://github.com/apache/airflow/pull/37028#issuecomment-2149658004 @uranusjr could you pls review the doc commit , thanks -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the UR

Re: [PR] feature: callable for template_fields [airflow]

2024-06-06 Thread via GitHub
raphaelauv commented on PR #37028: URL: https://github.com/apache/airflow/pull/37028#issuecomment-2151645959 thanks for the doc , I added a new test about nested fields -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use t

Re: [PR] feature: callable for template_fields [airflow]

2024-06-07 Thread via GitHub
uranusjr commented on code in PR #37028: URL: https://github.com/apache/airflow/pull/37028#discussion_r1630868400 ## tests/operators/test_python.py: ## @@ -229,6 +229,21 @@ def test_python_callable_keyword_arguments_are_templatized(self): assert rendered_op_kwargs["a_d

Re: [PR] feature: callable for template_fields [airflow]

2024-06-07 Thread via GitHub
uranusjr commented on code in PR #37028: URL: https://github.com/apache/airflow/pull/37028#discussion_r1630868400 ## tests/operators/test_python.py: ## @@ -229,6 +229,21 @@ def test_python_callable_keyword_arguments_are_templatized(self): assert rendered_op_kwargs["a_d

Re: [PR] feature: callable for template_fields [airflow]

2024-06-08 Thread via GitHub
Dev-iL commented on code in PR #37028: URL: https://github.com/apache/airflow/pull/37028#discussion_r1632048857 ## docs/apache-airflow/core-concepts/operators.rst: ## @@ -211,64 +235,65 @@ Alternatively, if you want to prevent Airflow from treating a value as a referen Renderi

Re: [PR] feature: callable for template_fields [airflow]

2024-06-09 Thread via GitHub
raphaelauv commented on code in PR #37028: URL: https://github.com/apache/airflow/pull/37028#discussion_r1632297416 ## docs/apache-airflow/core-concepts/operators.rst: ## @@ -211,64 +235,65 @@ Alternatively, if you want to prevent Airflow from treating a value as a referen Ren

Re: [PR] feature: callable for template_fields [airflow]

2024-06-09 Thread via GitHub
Dev-iL commented on code in PR #37028: URL: https://github.com/apache/airflow/pull/37028#discussion_r1632299745 ## docs/apache-airflow/core-concepts/operators.rst: ## @@ -211,64 +235,65 @@ Alternatively, if you want to prevent Airflow from treating a value as a referen Renderi

Re: [PR] feature: callable for template_fields [airflow]

2024-06-11 Thread via GitHub
potiuk merged PR #37028: URL: https://github.com/apache/airflow/pull/37028 -- 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-unsubscr...@airflow.a