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/14 13:26:16 UTC

[GitHub] [airflow] uranusjr opened a new pull request #18244: Make sure task view can be rendered without a ti

uranusjr opened a new pull request #18244:
URL: https://github.com/apache/airflow/pull/18244


   Fix #18242, fix #18188.
   
   These views should now work, but I want to add a couple of tests for these views as well.


-- 
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 #18244: Make sure task view can be rendered without a ti

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


   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 commented on pull request #18244: Make sure task view can be rendered without a ti

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


   Forgot to mention:
   
   * The “task” view should now show “No Task Instance Available” instead of the “Task Instance Attributes” table (most of the values in the table are meaningless anyway since they are not “real” without an actual DAG run).
   * The “rendered” view should work properly as in Airflow 2.1.x.


-- 
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 merged pull request #18244: Make sure task view can be rendered without a ti

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


   


-- 
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 #18244: Make sure task view can be rendered without a ti

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



##########
File path: airflow/www/templates/airflow/task.html
##########
@@ -43,18 +43,22 @@ <h5>Dependencies Blocking Task From Getting Scheduled</h5>
       <h5>Attribute: {{ attr }}</h5>
       {{ value }}
     {% endfor %}
-    <h5>Task Instance Attributes</h5>
-    <table class="table table-striped table-bordered">
-      <tr>
-        <th>Attribute</th>
-        <th>Value</th>
-      </tr>
-      {% for attr, value in ti_attrs %}
+    {% if ti_attrs is none %}
+      <h5>No Task Instance Available</h5>
+    {% else %}
+      <h5>Task Instance Attributes</h5>
+      <table class="table table-striped table-bordered">
         <tr>
-          <td>{{ attr }}</td>
-          <td class="code js-ti-attr">{{ value }}</td>
+          <th>Attribute</th>
+          <th>Value</th>
         </tr>
-      {% endfor %}
+        {% for attr, value in ti_attrs %}
+          <tr>
+            <td>{{ attr }}</td>
+            <td class="code js-ti-attr">{{ value }}</td>
+          </tr>
+        {% endfor %}
+      {% endif %}

Review comment:
       ```suggestion
           </table>
         {% endif %}
   ```
   We should keep the whole table inside the if-else block




-- 
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 #18244: Make sure task view can be rendered without a ti

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



##########
File path: airflow/www/templates/airflow/task.html
##########
@@ -43,18 +43,22 @@ <h5>Dependencies Blocking Task From Getting Scheduled</h5>
       <h5>Attribute: {{ attr }}</h5>
       {{ value }}
     {% endfor %}
-    <h5>Task Instance Attributes</h5>
-    <table class="table table-striped table-bordered">
-      <tr>
-        <th>Attribute</th>
-        <th>Value</th>
-      </tr>
-      {% for attr, value in ti_attrs %}
+    {% if ti_attrs is none %}
+      <h5>No Task Instance Available</h5>
+    {% else %}
+      <h5>Task Instance Attributes</h5>
+      <table class="table table-striped table-bordered">
         <tr>
-          <td>{{ attr }}</td>
-          <td class="code js-ti-attr">{{ value }}</td>
+          <th>Attribute</th>
+          <th>Value</th>
         </tr>
-      {% endfor %}
+        {% for attr, value in ti_attrs %}
+          <tr>
+            <td>{{ attr }}</td>
+            <td class="code js-ti-attr">{{ value }}</td>
+          </tr>
+        {% endfor %}
+      {% endif %}

Review comment:
       Oops, thanks for spotting 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 specific comment.

To unsubscribe, e-mail: commits-unsubscribe@airflow.apache.org

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