Github user artemrd commented on a diff in the pull request:
https://github.com/apache/spark/pull/21114#discussion_r186896584
--- Diff: core/src/test/scala/org/apache/spark/AccumulatorSuite.scala ---
@@ -209,10 +209,8 @@ class AccumulatorSuite extends SparkFunSuite with
Matchers with LocalSparkContex
System.gc()
assert(ref.get.isEmpty)
- // Getting a garbage collected accum should throw error
- intercept[IllegalStateException] {
- AccumulatorContext.get(accId)
- }
+ // Getting a garbage collected accum should return None.
+ assert(AccumulatorContext.get(accId).isEmpty)
--- End diff --
Added a test.
---
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]