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 2020/10/11 22:11:26 UTC

[GitHub] [airflow] kaxil opened a new pull request #11447: Use PyUpgrade to use Python 3.6 features

kaxil opened a new pull request #11447:
URL: https://github.com/apache/airflow/pull/11447


   Use features like `f-strings` instead of format across the code-base.
   
   More details: https://github.com/asottile/pyupgrade
   
   
   <!--
   Thank you for contributing! Please make sure that your code changes
   are covered with tests. And in case of new features or big changes
   remember to adjust the documentation.
   
   Feel free to ping committers for the review!
   
   In case of existing issue, reference it using one of the following:
   
   closes: #ISSUE
   related: #ISSUE
   
   How to write a good git commit message:
   http://chris.beams.io/posts/git-commit/
   -->
   
   ---
   **^ Add meaningful description above**
   
   Read the **[Pull Request Guidelines](https://github.com/apache/airflow/blob/master/CONTRIBUTING.rst#pull-request-guidelines)** for more information.
   In case of fundamental code change, Airflow Improvement Proposal ([AIP](https://cwiki.apache.org/confluence/display/AIRFLOW/Airflow+Improvements+Proposals)) is needed.
   In case of a new dependency, check compliance with the [ASF 3rd Party License Policy](https://www.apache.org/legal/resolved.html#category-x).
   In case of backwards incompatible changes please leave a note in [UPDATING.md](https://github.com/apache/airflow/blob/master/UPDATING.md).
   


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

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [airflow] kaxil merged pull request #11447: Use PyUpgrade to use Python 3.6 features

Posted by GitBox <gi...@apache.org>.
kaxil merged pull request #11447:
URL: https://github.com/apache/airflow/pull/11447


   


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

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [airflow] github-actions[bot] commented on pull request #11447: Use PyUpgrade to use Python 3.6 features

Posted by GitBox <gi...@apache.org>.
github-actions[bot] commented on pull request #11447:
URL: https://github.com/apache/airflow/pull/11447#issuecomment-715916889


   [The Workflow run](https://github.com/apache/airflow/actions/runs/325975561) is cancelling this PR. It has some failed jobs matching ^Pylint$,^Static checks$,^Build docs$,^Spell check docs$,^Backport packages$,^Checks: Helm tests$,^Test OpenAPI*.


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

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [airflow] kaxil commented on pull request #11447: Use PyUpgrade to use Python 3.6 features

Posted by GitBox <gi...@apache.org>.
kaxil commented on pull request #11447:
URL: https://github.com/apache/airflow/pull/11447#issuecomment-721355028


   @turbaszek This is ready for review, as soon as this is merged. I will quickly rebased and make https://github.com/apache/airflow/pull/9550 pass the test too


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

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [airflow] kaxil commented on pull request #11447: Use PyUpgrade to use Python 3.6 features

Posted by GitBox <gi...@apache.org>.
kaxil commented on pull request #11447:
URL: https://github.com/apache/airflow/pull/11447#issuecomment-706775469


   @turbaszek Since backport packages are Python 3.6+ too, so upgrading them is fine too, right?


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

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [airflow] github-actions[bot] commented on pull request #11447: Use PyUpgrade to use Python 3.6 features

Posted by GitBox <gi...@apache.org>.
github-actions[bot] commented on pull request #11447:
URL: https://github.com/apache/airflow/pull/11447#issuecomment-706778594


   [The Workflow run](https://github.com/apache/airflow/actions/runs/301070948) is cancelling this PR. It has some failed jobs matching ^Pylint$,^Static checks$,^Build docs$,^Spell check docs$,^Backport packages$,^Checks: Helm tests$,^Test OpenAPI*.


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

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [airflow] XD-DENG commented on a change in pull request #11447: Use PyUpgrade to use Python 3.6 features

Posted by GitBox <gi...@apache.org>.
XD-DENG commented on a change in pull request #11447:
URL: https://github.com/apache/airflow/pull/11447#discussion_r516948836



##########
File path: .pre-commit-config.yaml
##########
@@ -177,6 +177,11 @@ repos:
       - id: fix-encoding-pragma
         args:
           - --remove
+  - repo: https://github.com/asottile/pyupgrade
+    rev: v2.7.2

Review comment:
       LGTM.
   
   A minor question: shall we use the latest v2.7.3?




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

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [airflow] turbaszek commented on pull request #11447: Use PyUpgrade to use Python 3.6 features

Posted by GitBox <gi...@apache.org>.
turbaszek commented on pull request #11447:
URL: https://github.com/apache/airflow/pull/11447#issuecomment-706775849


   > @turbaszek Since backport packages are Python 3.6+ too, so upgrading them is fine too, right?
   
   Yes, but I'm afraid this change may cause a lot of merge conflict with currently open PRs. I think we should wait with it for 2.0-alpha, probably apply it at the same moment as black


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

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [airflow] kaxil edited a comment on pull request #11447: Use PyUpgrade to use Python 3.6 features

Posted by GitBox <gi...@apache.org>.
kaxil edited a comment on pull request #11447:
URL: https://github.com/apache/airflow/pull/11447#issuecomment-721355028






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

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [airflow] mik-laj commented on a change in pull request #11447: Use PyUpgrade to use Python 3.6 features

Posted by GitBox <gi...@apache.org>.
mik-laj commented on a change in pull request #11447:
URL: https://github.com/apache/airflow/pull/11447#discussion_r503586610



##########
File path: airflow/cli/commands/dag_command.py
##########
@@ -112,10 +112,10 @@ def dag_backfill(args, dag=None):
         run_conf = json.loads(args.conf)
 
     if args.dry_run:
-        print("Dry run of DAG {0} on {1}".format(args.dag_id,
+        print("Dry run of DAG {} on {}".format(args.dag_id,
                                                  args.start_date))

Review comment:
       ```suggestion
                                                  args.start_date))
   ```




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

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [airflow] kaxil commented on pull request #11447: Use PyUpgrade to use Python 3.6 features

Posted by GitBox <gi...@apache.org>.
kaxil commented on pull request #11447:
URL: https://github.com/apache/airflow/pull/11447#issuecomment-706776005


   > > @turbaszek Since backport packages are Python 3.6+ too, so upgrading them is fine too, right?
   > 
   > Yes, but I'm afraid this change may cause a lot of merge conflict with currently open PRs. I think we should wait with it for 2.0-alpha, probably apply it at the same moment as black
   
   Yup, this PR can wait :)


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

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [airflow] github-actions[bot] commented on pull request #11447: Use PyUpgrade to use Python 3.6 features

Posted by GitBox <gi...@apache.org>.
github-actions[bot] commented on pull request #11447:
URL: https://github.com/apache/airflow/pull/11447#issuecomment-721116985


   [The Workflow run](https://github.com/apache/airflow/actions/runs/343658135) is cancelling this PR. It has some failed jobs matching ^Pylint$,^Static checks,^Build docs$,^Spell check docs$,^Backport packages$,^Provider packages,^Checks: Helm tests$,^Test OpenAPI*.


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

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [airflow] github-actions[bot] removed a comment on pull request #11447: Use PyUpgrade to use Python 3.6 features

Posted by GitBox <gi...@apache.org>.
github-actions[bot] removed a comment on pull request #11447:
URL: https://github.com/apache/airflow/pull/11447#issuecomment-706778594






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

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [airflow] kaxil commented on a change in pull request #11447: Use PyUpgrade to use Python 3.6 features

Posted by GitBox <gi...@apache.org>.
kaxil commented on a change in pull request #11447:
URL: https://github.com/apache/airflow/pull/11447#discussion_r516964184



##########
File path: .pre-commit-config.yaml
##########
@@ -177,6 +177,11 @@ repos:
       - id: fix-encoding-pragma
         args:
           - --remove
+  - repo: https://github.com/asottile/pyupgrade
+    rev: v2.7.2

Review comment:
       Good call, will update




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

For queries about this service, please contact Infrastructure at:
users@infra.apache.org