[GitHub] spark pull request #22577: [CORE][MINOR] Fix obvious error and compiling for...

2018-09-30 Thread asfgit
Github user asfgit closed the pull request at:

https://github.com/apache/spark/pull/22577


---

-
To unsubscribe, e-mail: reviews-unsubscr...@spark.apache.org
For additional commands, e-mail: reviews-h...@spark.apache.org



[GitHub] spark pull request #22577: [CORE][MINOR] Fix obvious error and compiling for...

2018-09-28 Thread dongjoon-hyun
Github user dongjoon-hyun commented on a diff in the pull request:

https://github.com/apache/spark/pull/22577#discussion_r221410603
  
--- Diff: 
core/src/main/scala/org/apache/spark/status/api/v1/OneApplicationResource.scala 
---
@@ -175,7 +175,7 @@ private[v1] class OneApplicationAttemptResource extends 
AbstractApplicationResou
   def getAttempt(): ApplicationAttemptInfo = {
 uiRoot.getApplicationInfo(appId)
   .flatMap { app =>
-app.attempts.filter(_.attemptId == attemptId).headOption
--- End diff --

@sadhen Since this is a general code fix for 
`master/branch-2.4/branch-2.3`. Can we update the title without mentioning 
`compiling for Scala 2.12.7`?
> branch-2.2 is fine, but branch-2.3 should be fixed.


---

-
To unsubscribe, e-mail: reviews-unsubscr...@spark.apache.org
For additional commands, e-mail: reviews-h...@spark.apache.org



[GitHub] spark pull request #22577: [CORE][MINOR] Fix obvious error and compiling for...

2018-09-28 Thread srowen
Github user srowen commented on a diff in the pull request:

https://github.com/apache/spark/pull/22577#discussion_r221272009
  
--- Diff: 
core/src/main/scala/org/apache/spark/status/api/v1/OneApplicationResource.scala 
---
@@ -175,7 +175,7 @@ private[v1] class OneApplicationAttemptResource extends 
AbstractApplicationResou
   def getAttempt(): ApplicationAttemptInfo = {
 uiRoot.getApplicationInfo(appId)
   .flatMap { app =>
-app.attempts.filter(_.attemptId == attemptId).headOption
--- End diff --

I don't think it's a compile error, but a warning, which might be new in 
2.12. I tried to fix up a bunch of these in 
https://github.com/apache/spark/commit/cfbdd6a1f5906b848c520d3365cc4034992215d9 
for example.


---

-
To unsubscribe, e-mail: reviews-unsubscr...@spark.apache.org
For additional commands, e-mail: reviews-h...@spark.apache.org



[GitHub] spark pull request #22577: [CORE][MINOR] Fix obvious error and compiling for...

2018-09-27 Thread HyukjinKwon
Github user HyukjinKwon commented on a diff in the pull request:

https://github.com/apache/spark/pull/22577#discussion_r221137927
  
--- Diff: 
core/src/main/scala/org/apache/spark/status/api/v1/OneApplicationResource.scala 
---
@@ -175,7 +175,7 @@ private[v1] class OneApplicationAttemptResource extends 
AbstractApplicationResou
   def getAttempt(): ApplicationAttemptInfo = {
 uiRoot.getApplicationInfo(appId)
   .flatMap { app =>
-app.attempts.filter(_.attemptId == attemptId).headOption
--- End diff --

Yea, can you share the error message?


---

-
To unsubscribe, e-mail: reviews-unsubscr...@spark.apache.org
For additional commands, e-mail: reviews-h...@spark.apache.org



[GitHub] spark pull request #22577: [CORE][MINOR] Fix obvious error and compiling for...

2018-09-27 Thread cloud-fan
Github user cloud-fan commented on a diff in the pull request:

https://github.com/apache/spark/pull/22577#discussion_r221136204
  
--- Diff: 
core/src/main/scala/org/apache/spark/status/api/v1/OneApplicationResource.scala 
---
@@ -175,7 +175,7 @@ private[v1] class OneApplicationAttemptResource extends 
AbstractApplicationResou
   def getAttempt(): ApplicationAttemptInfo = {
 uiRoot.getApplicationInfo(appId)
   .flatMap { app =>
-app.attempts.filter(_.attemptId == attemptId).headOption
--- End diff --

hmm, just curious, why this doesn't compile in 2.12.7?


---

-
To unsubscribe, e-mail: reviews-unsubscr...@spark.apache.org
For additional commands, e-mail: reviews-h...@spark.apache.org



[GitHub] spark pull request #22577: [CORE][MINOR] Fix obvious error and compiling for...

2018-09-27 Thread sadhen
GitHub user sadhen opened a pull request:

https://github.com/apache/spark/pull/22577

[CORE][MINOR] Fix obvious error and compiling for Scala 2.12.7

## What changes were proposed in this pull request?

Fix an obvious error.

## How was this patch tested?

Existing tests.


You can merge this pull request into a Git repository by running:

$ git pull https://github.com/sadhen/spark minor_fix

Alternatively you can review and apply these changes as the patch at:

https://github.com/apache/spark/pull/22577.patch

To close this pull request, make a commit to your master/trunk branch
with (at least) the following in the commit message:

This closes #22577


commit 1fa56185d69e5ba9a23d911ccaf844a967880068
Author: Darcy Shen 
Date:   2018-09-28T03:33:07Z

Fix obvious error and compiling for Scala 2.12.7




---

-
To unsubscribe, e-mail: reviews-unsubscr...@spark.apache.org
For additional commands, e-mail: reviews-h...@spark.apache.org