question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

ConcurrentModificationException in LoadReportersWorkAction

See original GitHub issue

Sometime but not always we get a ConcurrentModificationException from this gradle plugin when it is in the LoadReportersWorkAction.

We have several kotlin modules (mixed with java modules) and the ktLint check runs there in parallel. We run the task ktlintCheck. Each module configures ktLint with the CHECKSTYLE reporter like this:

ktlint {
    reporters {
        reporter(ReporterType.CHECKSTYLE)
    }
}

We are using v10.1.0.

FAILURE: Build failed with an exception.
* What went wrong:
 Execution failed for task ':loadKtlintReporters'.
   A failure occurred while executing org.jlleitschuh.gradle.ktlint.worker.LoadReportersWorkAction
    Could not serialize unit of work.
      java.util.ConcurrentModificationException (no error message)

is this a plugin problem or should we configure the reporters in a different manner?

Issue Analytics

  • State:open
  • Created 2 years ago
  • Comments:6 (2 by maintainers)

github_iconTop GitHub Comments

1reaction
JLLeitschuhcommented, Nov 30, 2021

Proposed fix: https://github.com/gradle/gradle/pull/19170

Idk if that will actually fix the issue, but it might.

1reaction
sciccommented, Aug 11, 2021

We have 15 Kotlin subprojects in the build. In each ktLint is enabled. (There are about 60 more java subprojects.) Since the ConcurrentModificationException only happens rarely (about every 50th to 100th build) I don’t have a full stacktrace at hand. But will try to provide one next time.

Read more comments on GitHub >

github_iconTop Results From Across the Web

How to avoid java.util.ConcurrentModificationException when ...
I have an ArrayList that I want to iterate over. While iterating over it I have to remove elements at the same time....
Read more >
Fix the ConcurrentModificationException | TechTarget
Java's ConcurrentModificationException is thrown when a collection is modified while a Java Iterator is trying to loop through it.
Read more >
How to Avoid/Fix ConcurrentModificationException ... - Java67
You can fix ConcurrentModificationException by changing your code and instead of using ArrayList. remove() method just use Iterator. remove() method in Java.
Read more >
[BUG][ENV] When debugging the gitlab plugin, it prompts that the ...
Problem with umlauts in usernames, 3, 2020-12-19, 2022-09-25. ConcurrentModificationException in LoadReportersWorkAction, 6, 2021-08-03, 2022-10-07.
Read more >
Export a notebook as it is onscreen. - Jupyterlab/Jupyterlab - IssueHint
ConcurrentModificationException in LoadReportersWorkAction, 6, 2021-08-03, 2022-10-07. Exit trap is wrongfully triggered when `--help` is issued ...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found