Github user srowen commented on a diff in the pull request:
https://github.com/apache/spark/pull/12776#discussion_r61585641
--- Diff:
core/src/test/scala/org/apache/spark/InternalAccumulatorSuite.scala ---
@@ -188,13 +188,18 @@ class InternalAccumulatorSuite extends SparkFunSuite
with LocalSparkContext {
val numInternalAccums = TaskMetrics.empty.internalAccums.length
// We ran 2 stages, so we should have 2 sets of internal accumulators,
1 for each stage
assert(AccumulatorContext.numAccums === numInternalAccums * 2)
+ val cnt = 0
val accumsRegistered = sc.cleaner match {
- case Some(cleaner: SaveAccumContextCleaner) =>
cleaner.accumsRegisteredForCleanup
+ case Some(cleaner: SaveAccumContextCleaner) => {
--- End diff --
accumsRegistered is not used now. You don't need to count the number of
elements, just get its size. Then you can assert for each that it isDefined
rather than != None.
---
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]