Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Progressbar error:Exception in thread "main" java.lang.NoSuchMethodError: org.jline.terminal.TerminalBuilder.dumb(Z)Lorg/jline/terminal/TerminalBuilder; #160

Open
niuzhi opened this issue Mar 4, 2024 · 1 comment
Labels

Comments

@niuzhi
Copy link

niuzhi commented Mar 4, 2024

Hello, I am using progressbar to build an application. At the same time, I have also introduced the kotlin-compiler package into my project. When using ProgressBar to build the terminal, I always call the jline library under the kotlin-compiler package instead of the dependency of Processbar. The jline library causes the following exception. How should I solve it?

image

my environment:
pom.xml


me.tongfei
progressbar
0.9.5


org.apache.logging.log4j
log4j-api
2.17.1


org.apache.logging.log4j
log4j-core
2.17.1


org.jline
jline
3.21.0


org.jetbrains.kotlin
kotlin-compiler
1.7.22

code:
public class Main {
public static void main(String[] args) {

    List<String> data = new ArrayList<>();
    data.add("a");
    data.add("b");
    ProgressBarBuilder pbb = (new ProgressBarBuilder()).setInitialMax(2).setTaskName("Test").setStyle(ProgressBarStyle.ASCII);

    Iterator iterator = ProgressBar.wrap(data, pbb).iterator();
   
}

}

@ctongfei ctongfei added the jline label Mar 6, 2024
@ctongfei
Copy link
Owner

ctongfei commented Mar 6, 2024

What jline version does your Kotlin-compiler depend on? It seems to me that this is a Java JAR linking error: there may be 2 versions of jline in conflict, so that org.jline.terminal.TerminalBuilder.dumb is not found?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants