Github user srowen commented on a diff in the pull request:
https://github.com/apache/spark/pull/18645#discussion_r127611376
--- Diff:
core/src/test/scala/org/apache/spark/scheduler/TaskContextSuite.scala ---
@@ -54,7 +54,10 @@ class TaskContextSuite extends SparkFunSuite with
BeforeAndAfter with LocalSpark
val rdd = new RDD[String](sc, List()) {
override def getPartitions = Array[Partition](StubPartition(0))
override def compute(split: Partition, context: TaskContext) = {
- context.addTaskCompletionListener(context =>
TaskContextSuite.completed = true)
+ context.addTaskCompletionListener(new TaskCompletionListener {
--- End diff --
Changes like this resolve an ambiguity where two overloads of a method
exist, one with a signature taking a lambda, and the other taking a
trait/interface of one method, both of which could fit. In cases like this I
resolved in favor of implementing a specific listener class.
---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at [email protected] or file a JIRA ticket
with INFRA.
---
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]