You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@airflow.apache.org by GitBox <gi...@apache.org> on 2022/12/13 06:08:13 UTC

[GitHub] [airflow] ephraimbuddy opened a new pull request, #28324: Add `version_renamed` and `previous_name` in config sections

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

   The `previous_name` and `version_renamed` fields were added to the configuration section to track the previous name and the version in which it was renamed for a given configuration option.
   
   This also helps us retain the version-added value of config options when the config section is renamed.
   
   This information of rename is also made available in the config documentation
   
   Closes: https://github.com/apache/airflow/pull/28076
   


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


[GitHub] [airflow] uranusjr commented on a diff in pull request #28324: Add `version_renamed` and `previous_name` in config sections

Posted by GitBox <gi...@apache.org>.
uranusjr commented on code in PR #28324:
URL: https://github.com/apache/airflow/pull/28324#discussion_r1046786955


##########
docs/apache-airflow/configurations-ref.rst:
##########
@@ -48,6 +48,10 @@ that you run airflow components on is synchronized (for example using ntpd) othe
     [{{ section["name"] }}]
     {{ "=" * (section["name"]|length + 2) }}
 
+    {% if section.get('renamed') %}

Review Comment:
   ```suggestion
       {% if 'renamed' in section %}
   ```
   
   Does this work? I feel Jinja2 is in some sort of an uncanny valley to Python that most things work but not all things…



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


[GitHub] [airflow] jedcunningham commented on a diff in pull request #28324: Add `version_renamed` and `previous_name` in config sections

Posted by GitBox <gi...@apache.org>.
jedcunningham commented on code in PR #28324:
URL: https://github.com/apache/airflow/pull/28324#discussion_r1047906563


##########
docs/apache-airflow/configurations-ref.rst:
##########
@@ -48,6 +48,10 @@ that you run airflow components on is synchronized (for example using ntpd) othe
     [{{ section["name"] }}]
     {{ "=" * (section["name"]|length + 2) }}
 
+    {% if 'renamed' in section %}
+    *{{"Renamed in version "+ section['renamed']['version']+", previous name was "+ section['renamed']['previous_name'] }}*

Review Comment:
   ```suggestion
       *Renamed in version {{ section['renamed']['version'] }}, previous name was {{ section['renamed']['previous_name'] }}*
   ```
   
   nit, assuming this works this seems cleaner?



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


[GitHub] [airflow] ephraimbuddy commented on a diff in pull request #28324: Add `version_renamed` and `previous_name` in config sections

Posted by GitBox <gi...@apache.org>.
ephraimbuddy commented on code in PR #28324:
URL: https://github.com/apache/airflow/pull/28324#discussion_r1046792595


##########
docs/apache-airflow/configurations-ref.rst:
##########
@@ -48,6 +48,10 @@ that you run airflow components on is synchronized (for example using ntpd) othe
     [{{ section["name"] }}]
     {{ "=" * (section["name"]|length + 2) }}
 
+    {% if section.get('renamed') %}

Review Comment:
   Both works. Confirmed by building the doc



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


[GitHub] [airflow] uranusjr commented on pull request #28324: Add `version_renamed` and `previous_name` in config sections

Posted by GitBox <gi...@apache.org>.
uranusjr commented on PR #28324:
URL: https://github.com/apache/airflow/pull/28324#issuecomment-1347806060

   Instead of adding a bunch of `~`, would it be simpler to omit them and use `get('previous_name')` instead?
   
   I also wonder if it’s better to do
   
   ```yaml
   renamed:
     previous_name: ...
     version: ...
   ```
   
   so it’s clearer the two keys must appear together.


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


[GitHub] [airflow] ephraimbuddy merged pull request #28324: Add `version_renamed` and `previous_name` in config sections

Posted by GitBox <gi...@apache.org>.
ephraimbuddy merged PR #28324:
URL: https://github.com/apache/airflow/pull/28324


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