srowen commented on a change in pull request #23637: [SPARK-26714][CORE][WEBUI] 
Show 0 partition job in WebUI
URL: https://github.com/apache/spark/pull/23637#discussion_r250850814
 
 

 ##########
 File path: core/src/main/scala/org/apache/spark/ui/UIUtils.scala
 ##########
 @@ -363,7 +363,8 @@ private[spark] object UIUtils extends Logging {
       skipped: Int,
       reasonToNumKilled: Map[String, Int],
       total: Int): Seq[Node] = {
-    val completeWidth = "width: %s%%".format((completed.toDouble/total)*100)
+    val ratio = if (total == completed) 100.0 else 
(completed.toDouble/total)*100
 
 Review comment:
   Oh right I get it , it matters when completed is 0. I guess that could be 
the check, even, for clarity

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
[email protected]


With regards,
Apache Git Services

---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to