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 2021/09/01 09:32:31 UTC
[GitHub] [airflow] bbovenzi opened a new pull request #17732: Add Next Run to UI
bbovenzi opened a new pull request #17732:
URL: https://github.com/apache/airflow/pull/17732
Adds info on the next run from `next_dagrun` in the hoem page list of all dags and on the individual dag pages.
#17726
Unfortunately, `next_dagrun` only existed on `DagModel` and not `Dag` so I had to manually add it to every relevant endpoint in `views.py`. I also had to do some weird js logic to format the dates in line with the rest of the UI.
~~Also, I tried to update the copy on execution date. Open to suggestions.~~ (Updating use of `execution_date` throughout the UI will be a different PR)
<img width="1619" alt="Screen Shot 2021-08-19 at 4 15 18 PM" src="https://user-images.githubusercontent.com/4600967/130084389-8bf90487-d04a-440e-a8db-c73a50237fa1.png">
<img width="1018" alt="Screen Shot 2021-08-19 at 4 14 59 PM" src="https://user-images.githubusercontent.com/4600967/130084426-e8db0bb6-9733-43a5-992f-07e29bb93143.png">
Closes #2460
---
**^ Add meaningful description above**
Read the **[Pull Request Guidelines](https://github.com/apache/airflow/blob/main/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/main/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.
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 #17732: Add Next Run to UI
Posted by GitBox <gi...@apache.org>.
uranusjr commented on pull request #17732:
URL: https://github.com/apache/airflow/pull/17732#issuecomment-909143605
Hmm a lot of tests failing, many seem to be related to the new `dag_model` addition to templates.
--
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 change in pull request #17732: Add Next Run to UI
Posted by GitBox <gi...@apache.org>.
uranusjr commented on a change in pull request #17732:
URL: https://github.com/apache/airflow/pull/17732#discussion_r692647739
##########
File path: airflow/www/templates/airflow/dags.html
##########
@@ -98,7 +98,10 @@ <h2>{{ page_title }}</h2>
</th>
<th>Schedule</th>
<th style="width:180px;">Last Run
- <span class="material-icons text-muted js-tooltip" aria-hidden="true" title="Execution Date/Time of Highest Dag Run.">info</span>
+ <span class="material-icons text-muted js-tooltip" aria-hidden="true" title="Logical Date/Time of the latest Dag Run.">info</span>
+ </th>
+ <th style="width:180px;">Next Run
+ <span class="material-icons text-muted js-tooltip" aria-hidden="true" title="Expected Date/Time of the next Dag Run.">info</span>
Review comment:
Good point, it’s the logical date I think. The next expected *run* time is available in `DagModel.next_dagrun_create_after`.
This raises another issue though—perhaps we should ditch all the logical date labels, and always display the current/next DAG run’s run date and data interval instead.
--
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 change in pull request #17732: Add Next Run to UI
Posted by GitBox <gi...@apache.org>.
uranusjr commented on a change in pull request #17732:
URL: https://github.com/apache/airflow/pull/17732#discussion_r692798190
##########
File path: airflow/www/templates/airflow/dags.html
##########
@@ -98,7 +98,10 @@ <h2>{{ page_title }}</h2>
</th>
<th>Schedule</th>
<th style="width:180px;">Last Run
- <span class="material-icons text-muted js-tooltip" aria-hidden="true" title="Execution Date/Time of Highest Dag Run.">info</span>
+ <span class="material-icons text-muted js-tooltip" aria-hidden="true" title="Logical Date/Time of the latest Dag Run.">info</span>
+ </th>
+ <th style="width:180px;">Next Run
+ <span class="material-icons text-muted js-tooltip" aria-hidden="true" title="Expected Date/Time of the next Dag Run.">info</span>
Review comment:
Or something like
```jinja
{% if dagrun.data_interval_start is not None or dagrun.data_interval_end is not None %}
{# Render data interval #}
{% else %}
{# Render logical date #}
{% endif %}
```
Since users probably would want to see `execution_date` for those old runs?
--
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] ashb commented on a change in pull request #17732: Add Next Run to UI
Posted by GitBox <gi...@apache.org>.
ashb commented on a change in pull request #17732:
URL: https://github.com/apache/airflow/pull/17732#discussion_r692493903
##########
File path: airflow/www/templates/airflow/dags.html
##########
@@ -98,7 +98,10 @@ <h2>{{ page_title }}</h2>
</th>
<th>Schedule</th>
<th style="width:180px;">Last Run
- <span class="material-icons text-muted js-tooltip" aria-hidden="true" title="Execution Date/Time of Highest Dag Run.">info</span>
+ <span class="material-icons text-muted js-tooltip" aria-hidden="true" title="Logical Date/Time of the latest Dag Run.">info</span>
+ </th>
+ <th style="width:180px;">Next Run
+ <span class="material-icons text-muted js-tooltip" aria-hidden="true" title="Expected Date/Time of the next Dag Run.">info</span>
Review comment:
What date does this show? Is it the logical date that is going to be created, or the time _when_ the run will be created?
I think we need to display both of these (though one should be in a tooltip I think)
--
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 change in pull request #17732: Add Next Run to UI
Posted by GitBox <gi...@apache.org>.
uranusjr commented on a change in pull request #17732:
URL: https://github.com/apache/airflow/pull/17732#discussion_r694771112
##########
File path: airflow/www/templates/airflow/dags.html
##########
@@ -98,7 +98,10 @@ <h2>{{ page_title }}</h2>
</th>
<th>Schedule</th>
<th style="width:180px;">Last Run
- <span class="material-icons text-muted js-tooltip" aria-hidden="true" title="Execution Date/Time of Highest Dag Run.">info</span>
+ <span class="material-icons text-muted js-tooltip" aria-hidden="true" title="Logical Date/Time of the latest Dag Run.">info</span>
+ </th>
+ <th style="width:180px;">Next Run
+ <span class="material-icons text-muted js-tooltip" aria-hidden="true" title="Expected Date/Time of the next Dag Run.">info</span>
Review comment:
Added, I think this should work.
--
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] bbovenzi commented on a change in pull request #17732: Add Next Run to UI
Posted by GitBox <gi...@apache.org>.
bbovenzi commented on a change in pull request #17732:
URL: https://github.com/apache/airflow/pull/17732#discussion_r694945886
##########
File path: airflow/www/templates/airflow/dag.html
##########
@@ -84,8 +84,17 @@ <h4 class="pull-right" style="user-select: none;-moz-user-select: auto;">
{{ state_token }}
{% endif %}
<a class="label label-default" href="{{ url_for('DagRunModelView.list') }}?_flt_3_dag_id={{ dag.dag_id }}">
- schedule: {{ dag.schedule_interval }}
+ Schedule: {{ dag.schedule_interval }}
</a>
+ {% if dag_model is defined and dag_model.next_dagrun is defined %}
+ <p class="label label-default" style="margin-left: 5px">
+ Next Run: <span id="next-run">{{ dag_model.next_dagrun }}</span>
Review comment:
`<time>` doesn't really help us here
--
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] ryanahamilton commented on a change in pull request #17732: Add Next Run to UI
Posted by GitBox <gi...@apache.org>.
ryanahamilton commented on a change in pull request #17732:
URL: https://github.com/apache/airflow/pull/17732#discussion_r692933421
##########
File path: airflow/www/templates/airflow/dags.html
##########
@@ -170,12 +173,16 @@ <h2>{{ page_title }}</h2>
<a></a>
<span aria-hidden="true" title=" " class="material-icons text-muted js-tooltip" style="display:none">info</span>
</td>
- {# Column 7: Recent Tasks #}
+ {# Column 7: Next Run #}
+ <td class="text-nowrap next-run">
+ {{ dag.next_dagrun }}
+ </td>
+ {# Column 8: Recent Tasks #}
<td style="padding:0; width:323px; height:10px;">
{{ loading_dots(classes='js-loading-task-stats text-muted') }}
<svg height="10" width="10" id='task-run-{{ dag.safe_dag_id }}' style="display: block;"></svg>
</td>
- {# Column 8: Actions #}
+ {# Column 9: Actions #}
Review comment:
We should probably just remove all of these comments. They're a bit superfluous and more nuisance than helpful IMO.
--
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 closed pull request #17732: Add Next Run to UI
Posted by GitBox <gi...@apache.org>.
uranusjr closed pull request #17732:
URL: https://github.com/apache/airflow/pull/17732
--
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 change in pull request #17732: Add Next Run to UI
Posted by GitBox <gi...@apache.org>.
uranusjr commented on a change in pull request #17732:
URL: https://github.com/apache/airflow/pull/17732#discussion_r694771112
##########
File path: airflow/www/templates/airflow/dags.html
##########
@@ -98,7 +98,10 @@ <h2>{{ page_title }}</h2>
</th>
<th>Schedule</th>
<th style="width:180px;">Last Run
- <span class="material-icons text-muted js-tooltip" aria-hidden="true" title="Execution Date/Time of Highest Dag Run.">info</span>
+ <span class="material-icons text-muted js-tooltip" aria-hidden="true" title="Logical Date/Time of the latest Dag Run.">info</span>
+ </th>
+ <th style="width:180px;">Next Run
+ <span class="material-icons text-muted js-tooltip" aria-hidden="true" title="Expected Date/Time of the next Dag Run.">info</span>
Review comment:
Added, I think this should work. `data_interval_start` and `data_interval_end` can be both `None` or both a datetime string (never one string and one None).
--
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] bbovenzi merged pull request #17732: Add Next Run to UI
Posted by GitBox <gi...@apache.org>.
bbovenzi merged pull request #17732:
URL: https://github.com/apache/airflow/pull/17732
--
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] ryanahamilton commented on a change in pull request #17732: Add Next Run to UI
Posted by GitBox <gi...@apache.org>.
ryanahamilton commented on a change in pull request #17732:
URL: https://github.com/apache/airflow/pull/17732#discussion_r692936090
##########
File path: airflow/www/templates/airflow/dags.html
##########
@@ -170,12 +173,16 @@ <h2>{{ page_title }}</h2>
<a></a>
<span aria-hidden="true" title=" " class="material-icons text-muted js-tooltip" style="display:none">info</span>
</td>
- {# Column 7: Recent Tasks #}
+ {# Column 7: Next Run #}
+ <td class="text-nowrap next-run">
Review comment:
We've been using a `js-` prefix for classes used for scripting (not styling) purposes.
```suggestion
<td class="text-nowrap js-next-run">
```
--
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 #17732: Add Next Run to UI
Posted by GitBox <gi...@apache.org>.
uranusjr commented on pull request #17732:
URL: https://github.com/apache/airflow/pull/17732#issuecomment-909143605
Hmm a lot of tests failing, many seem to be related to the new `dag_model` addition to templates.
--
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 change in pull request #17732: Add Next Run to UI
Posted by GitBox <gi...@apache.org>.
uranusjr commented on a change in pull request #17732:
URL: https://github.com/apache/airflow/pull/17732#discussion_r694781127
##########
File path: airflow/www/templates/airflow/dags.html
##########
@@ -98,7 +98,10 @@ <h2>{{ page_title }}</h2>
</th>
<th>Schedule</th>
<th style="width:180px;">Last Run
- <span class="material-icons text-muted js-tooltip" aria-hidden="true" title="Execution Date/Time of Highest Dag Run.">info</span>
+ <span class="material-icons text-muted js-tooltip" aria-hidden="true" title="Logical Date/Time of the latest Dag Run.">info</span>
+ </th>
+ <th style="width:180px;">Next Run
+ <span class="material-icons text-muted js-tooltip" aria-hidden="true" title="Expected Date/Time of the next Dag Run.">info</span>
Review comment:
Pushed, I think this should work…
--
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 #17732: Add Next Run to UI
Posted by GitBox <gi...@apache.org>.
uranusjr commented on pull request #17732:
URL: https://github.com/apache/airflow/pull/17732#issuecomment-908213713
I just noticed something. We are using `next_dagrun_create_after` for Next Run, but is still using `execution_date` for Last Run. So for `example_bash_operator` (see screenshot in the top message), the runs are *two* hours apart even though the schedule is one hour. I think we should change Last Run to use `start_date` instead, does that sound righ @ashb?
--
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] bbovenzi merged pull request #17732: Add Next Run to UI
Posted by GitBox <gi...@apache.org>.
bbovenzi merged pull request #17732:
URL: https://github.com/apache/airflow/pull/17732
--
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] ashb commented on a change in pull request #17732: Add Next Run to UI
Posted by GitBox <gi...@apache.org>.
ashb commented on a change in pull request #17732:
URL: https://github.com/apache/airflow/pull/17732#discussion_r692494626
##########
File path: airflow/www/templates/airflow/dag.html
##########
@@ -84,8 +84,17 @@ <h4 class="pull-right" style="user-select: none;-moz-user-select: auto;">
{{ state_token }}
{% endif %}
<a class="label label-default" href="{{ url_for('DagRunModelView.list') }}?_flt_3_dag_id={{ dag.dag_id }}">
- schedule: {{ dag.schedule_interval }}
+ Schedule: {{ dag.schedule_interval }}
</a>
+ {% if dag_model is defined and dag_model.next_dagrun is defined %}
+ <p class="label label-default" style="margin-left: 5px">
+ Next Run: <span id="next-run">{{ dag_model.next_dagrun }}</span>
Review comment:
Make this a `<time>` element maybe?
--
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] bbovenzi commented on a change in pull request #17732: Add Next Run to UI
Posted by GitBox <gi...@apache.org>.
bbovenzi commented on a change in pull request #17732:
URL: https://github.com/apache/airflow/pull/17732#discussion_r698349299
##########
File path: airflow/www/templates/airflow/dag.html
##########
@@ -84,8 +84,17 @@ <h4 class="pull-right" style="user-select: none;-moz-user-select: auto;">
{{ state_token }}
{% endif %}
<a class="label label-default" href="{{ url_for('DagRunModelView.list') }}?_flt_3_dag_id={{ dag.dag_id }}">
- schedule: {{ dag.schedule_interval }}
+ Schedule: {{ dag.schedule_interval }}
</a>
+ {% if dag_model is defined and dag_model.next_dagrun_create_after is defined %}
+ <p class="label label-default" style="margin-left: 5px">
+ Next Run: <span id="next-run">{{ dag_model.next_dagrun_create_after }}</span>
Review comment:
Oh yes, I forgot that we select elements by `<time>` in `datetime_utils.js`. Fixed.
--
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 #17732: Add Next Run to UI
Posted by GitBox <gi...@apache.org>.
uranusjr commented on pull request #17732:
URL: https://github.com/apache/airflow/pull/17732#issuecomment-909143605
Hmm a lot of tests failing, many seem to be related to the new `dag_model` addition to templates.
--
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] potiuk commented on pull request #17732: Add Next Run to UI
Posted by GitBox <gi...@apache.org>.
potiuk commented on pull request #17732:
URL: https://github.com/apache/airflow/pull/17732#issuecomment-901998976
Thrlilled ! That's one of those great features that look like small ones but can totally change your experience.
--
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] ryanahamilton commented on a change in pull request #17732: Add Next Run to UI
Posted by GitBox <gi...@apache.org>.
ryanahamilton commented on a change in pull request #17732:
URL: https://github.com/apache/airflow/pull/17732#discussion_r692933421
##########
File path: airflow/www/templates/airflow/dags.html
##########
@@ -170,12 +173,16 @@ <h2>{{ page_title }}</h2>
<a></a>
<span aria-hidden="true" title=" " class="material-icons text-muted js-tooltip" style="display:none">info</span>
</td>
- {# Column 7: Recent Tasks #}
+ {# Column 7: Next Run #}
+ <td class="text-nowrap next-run">
+ {{ dag.next_dagrun }}
+ </td>
+ {# Column 8: Recent Tasks #}
<td style="padding:0; width:323px; height:10px;">
{{ loading_dots(classes='js-loading-task-stats text-muted') }}
<svg height="10" width="10" id='task-run-{{ dag.safe_dag_id }}' style="display: block;"></svg>
</td>
- {# Column 8: Actions #}
+ {# Column 9: Actions #}
Review comment:
We should probably just remove all of these comments. They're a bit superfluous and more puissance than helpful IMO.
--
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] bbovenzi commented on a change in pull request #17732: Add Next Run to UI
Posted by GitBox <gi...@apache.org>.
bbovenzi commented on a change in pull request #17732:
URL: https://github.com/apache/airflow/pull/17732#discussion_r694926015
##########
File path: airflow/www/templates/airflow/dags.html
##########
@@ -98,7 +98,10 @@ <h2>{{ page_title }}</h2>
</th>
<th>Schedule</th>
<th style="width:180px;">Last Run
- <span class="material-icons text-muted js-tooltip" aria-hidden="true" title="Execution Date/Time of Highest Dag Run.">info</span>
+ <span class="material-icons text-muted js-tooltip" aria-hidden="true" title="Logical Date/Time of the latest Dag Run.">info</span>
+ </th>
+ <th style="width:180px;">Next Run
+ <span class="material-icons text-muted js-tooltip" aria-hidden="true" title="Expected Date/Time of the next Dag Run.">info</span>
Review comment:
Actually, we use `execution_date` in a lot more parts of the UI. It should be a separate PR.
--
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 #17732: Add Next Run to UI
Posted by GitBox <gi...@apache.org>.
uranusjr commented on pull request #17732:
URL: https://github.com/apache/airflow/pull/17732#issuecomment-906288734
Since there are many execution_date usages to change, this will be done in a follow-up PR instead.
--
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] ashb commented on a change in pull request #17732: Add Next Run to UI
Posted by GitBox <gi...@apache.org>.
ashb commented on a change in pull request #17732:
URL: https://github.com/apache/airflow/pull/17732#discussion_r692753624
##########
File path: airflow/www/templates/airflow/dags.html
##########
@@ -98,7 +98,10 @@ <h2>{{ page_title }}</h2>
</th>
<th>Schedule</th>
<th style="width:180px;">Last Run
- <span class="material-icons text-muted js-tooltip" aria-hidden="true" title="Execution Date/Time of Highest Dag Run.">info</span>
+ <span class="material-icons text-muted js-tooltip" aria-hidden="true" title="Logical Date/Time of the latest Dag Run.">info</span>
+ </th>
+ <th style="width:180px;">Next Run
+ <span class="material-icons text-muted js-tooltip" aria-hidden="true" title="Expected Date/Time of the next Dag Run.">info</span>
Review comment:
@uranusjr Hmmm that might remove the ambiguity, yeah
Do we retroactively set data_interval on old runs when in our migration?
--
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 change in pull request #17732: Add Next Run to UI
Posted by GitBox <gi...@apache.org>.
uranusjr commented on a change in pull request #17732:
URL: https://github.com/apache/airflow/pull/17732#discussion_r694574213
##########
File path: airflow/www/templates/airflow/dags.html
##########
@@ -98,7 +98,10 @@ <h2>{{ page_title }}</h2>
</th>
<th>Schedule</th>
<th style="width:180px;">Last Run
- <span class="material-icons text-muted js-tooltip" aria-hidden="true" title="Execution Date/Time of Highest Dag Run.">info</span>
+ <span class="material-icons text-muted js-tooltip" aria-hidden="true" title="Logical Date/Time of the latest Dag Run.">info</span>
+ </th>
+ <th style="width:180px;">Next Run
+ <span class="material-icons text-muted js-tooltip" aria-hidden="true" title="Expected Date/Time of the next Dag Run.">info</span>
Review comment:
Oh… that’s a bit complicated due to how `query` is constructed… I’ll add a commit to your branch for this later (need to do something first).
--
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] github-actions[bot] commented on pull request #17732: Add Next Run to UI
Posted by GitBox <gi...@apache.org>.
github-actions[bot] commented on pull request #17732:
URL: https://github.com/apache/airflow/pull/17732#issuecomment-906287649
The PR is likely OK to be merged with just subset of tests for default Python and Database versions without running the full matrix of tests, because it does not modify the core of Airflow. If the committers decide that the full tests matrix is needed, they will add the label 'full tests needed'. Then you should rebase to the latest main or amend the last commit of the PR, and push it with --force-with-lease.
--
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 closed pull request #17732: Add Next Run to UI
Posted by GitBox <gi...@apache.org>.
uranusjr closed pull request #17732:
URL: https://github.com/apache/airflow/pull/17732
--
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] bbovenzi commented on pull request #17732: Add Next Run to UI
Posted by GitBox <gi...@apache.org>.
bbovenzi commented on pull request #17732:
URL: https://github.com/apache/airflow/pull/17732#issuecomment-908730558
I updated Next Run to use the execution date to be consistent with Last Run. I also added a tooltip for the next run to show the create after and data interval. For Last Run, I decided to extend the use of the `tiTooltip` we use in the tree view. All of these dates will also update whenever the app's timezone changes.
<img width="791" alt="Screen Shot 2021-08-30 at 11 56 22 PM" src="https://user-images.githubusercontent.com/4600967/131411330-1d5a3253-ce46-4f34-bf82-fed6f52749d2.png">
<img width="460" alt="Screen Shot 2021-08-30 at 11 56 34 PM" src="https://user-images.githubusercontent.com/4600967/131411334-60102f1e-38c8-4662-afef-25936ea18f04.png">
<img width="601" alt="Screen Shot 2021-08-30 at 11 56 37 PM" src="https://user-images.githubusercontent.com/4600967/131411338-03ecfe2d-81ed-4a82-91b1-58e2e920a4be.png">
--
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] ashb commented on a change in pull request #17732: Add Next Run to UI
Posted by GitBox <gi...@apache.org>.
ashb commented on a change in pull request #17732:
URL: https://github.com/apache/airflow/pull/17732#discussion_r698296795
##########
File path: airflow/www/templates/airflow/dag.html
##########
@@ -84,8 +84,17 @@ <h4 class="pull-right" style="user-select: none;-moz-user-select: auto;">
{{ state_token }}
{% endif %}
<a class="label label-default" href="{{ url_for('DagRunModelView.list') }}?_flt_3_dag_id={{ dag.dag_id }}">
- schedule: {{ dag.schedule_interval }}
+ Schedule: {{ dag.schedule_interval }}
</a>
+ {% if dag_model is defined and dag_model.next_dagrun_create_after is defined %}
+ <p class="label label-default" style="margin-left: 5px">
+ Next Run: <span id="next-run">{{ dag_model.next_dagrun_create_after }}</span>
Review comment:
By making this a `<time>` element it will automatically get converted by the [timezone selector](https://github.com/apache/airflow/blob/e4d3da16bad66aa40549cedac325d02e6b6559a9/airflow/www/static/js/datetime_utils.js#L74) (not to mention that just semantically this _is_ a time :grin:)
--
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 change in pull request #17732: Add Next Run to UI
Posted by GitBox <gi...@apache.org>.
uranusjr commented on a change in pull request #17732:
URL: https://github.com/apache/airflow/pull/17732#discussion_r692779639
##########
File path: airflow/www/templates/airflow/dags.html
##########
@@ -98,7 +98,10 @@ <h2>{{ page_title }}</h2>
</th>
<th>Schedule</th>
<th style="width:180px;">Last Run
- <span class="material-icons text-muted js-tooltip" aria-hidden="true" title="Execution Date/Time of Highest Dag Run.">info</span>
+ <span class="material-icons text-muted js-tooltip" aria-hidden="true" title="Logical Date/Time of the latest Dag Run.">info</span>
+ </th>
+ <th style="width:180px;">Next Run
+ <span class="material-icons text-muted js-tooltip" aria-hidden="true" title="Expected Date/Time of the next Dag Run.">info</span>
Review comment:
We don’t, but those can be calculated on the fly rather cheaply when needed. Or we could just display `data_interval_start` as *Unknown* (perhaps with a tooltip explaining why).
--
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] bbovenzi commented on pull request #17732: Add Next Run to UI
Posted by GitBox <gi...@apache.org>.
bbovenzi commented on pull request #17732:
URL: https://github.com/apache/airflow/pull/17732#issuecomment-908730558
I updated Next Run to use the execution date to be consistent with Last Run. I also added a tooltip for the next run to show the create after and data interval. For Last Run, I decided to extend the use of the `tiTooltip` we use in the tree view. All of these dates will also update whenever the app's timezone changes.
<img width="791" alt="Screen Shot 2021-08-30 at 11 56 22 PM" src="https://user-images.githubusercontent.com/4600967/131411330-1d5a3253-ce46-4f34-bf82-fed6f52749d2.png">
<img width="460" alt="Screen Shot 2021-08-30 at 11 56 34 PM" src="https://user-images.githubusercontent.com/4600967/131411334-60102f1e-38c8-4662-afef-25936ea18f04.png">
<img width="601" alt="Screen Shot 2021-08-30 at 11 56 37 PM" src="https://user-images.githubusercontent.com/4600967/131411338-03ecfe2d-81ed-4a82-91b1-58e2e920a4be.png">
--
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] bbovenzi commented on a change in pull request #17732: Add Next Run to UI
Posted by GitBox <gi...@apache.org>.
bbovenzi commented on a change in pull request #17732:
URL: https://github.com/apache/airflow/pull/17732#discussion_r693876177
##########
File path: airflow/www/templates/airflow/dags.html
##########
@@ -98,7 +98,10 @@ <h2>{{ page_title }}</h2>
</th>
<th>Schedule</th>
<th style="width:180px;">Last Run
- <span class="material-icons text-muted js-tooltip" aria-hidden="true" title="Execution Date/Time of Highest Dag Run.">info</span>
+ <span class="material-icons text-muted js-tooltip" aria-hidden="true" title="Logical Date/Time of the latest Dag Run.">info</span>
+ </th>
+ <th style="width:180px;">Next Run
+ <span class="material-icons text-muted js-tooltip" aria-hidden="true" title="Expected Date/Time of the next Dag Run.">info</span>
Review comment:
Right now we get the last run execution date and start time here: https://github.com/apache/airflow/blob/main/airflow/www/views.py#L919
How should we render it with data_interval?
--
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