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

Handle misconfigured CodeChecker plugin #141

Open
gyorb opened this issue Dec 3, 2018 · 1 comment
Open

Handle misconfigured CodeChecker plugin #141

gyorb opened this issue Dec 3, 2018 · 1 comment
Labels
Milestone

Comments

@gyorb
Copy link
Contributor

gyorb commented Dec 3, 2018

Until CodeChecker is not configured properly in the plugin an exception is thrown.

We should handle this exception and give an error message to the users that the plugin failed to detect CodeChecker and the user should check the plugin configuration.
In the console log in eclipse:

CodeChecker Plugin Started
tmux2: Failed to start server [Ljava.lang.StackTraceElement;@5296649

In the terminal where Eclipse was started:

java.lang.IllegalArgumentException: Couldn't run the specified CodeChecker for environment testing!
        at cc.codechecker.plugin.runtime.CodeCheckEnvironmentChecker.getCheckerEnvironment(CodeCheckEnvironmentChecker.java:100)
        at cc.codechecker.plugin.runtime.CodeCheckEnvironmentChecker.<init>(CodeCheckEnvironmentChecker.java:65)
        at cc.codechecker.plugin.config.CcConfiguration.updateServer(CcConfiguration.java:299)
        at cc.codechecker.plugin.config.CodeCheckerContext.getServerObject(CodeCheckerContext.java:180)
        at cc.codechecker.plugin.init.StartupJob.projectOpened(StartupJob.java:230)
        at cc.codechecker.plugin.init.StartupJob.runInUIThread(StartupJob.java:148)
        at cc.codechecker.plugin.init.StartupJob.run(StartupJob.java:48)
        at org.eclipse.core.internal.jobs.Worker.run(Worker.java:63)
@gyorb gyorb added the bug label Dec 3, 2018
@gyorb gyorb added this to the v0.0.7 milestone Dec 3, 2018
@vodorok
Copy link
Collaborator

vodorok commented Jan 3, 2019

In #140 large part of that stack trace got cut out.
I think this issue implicitly got fixed in that PR.
In details: The method call that throws the IllegalArgumentException has been removed from the CodeCheckEnvironmentChecker constructor, and the method itself is now static and is only being called from try-catch blocks.
This method was (and still is) used to set the preferences page warning info, that the path to CodeChecker binaries are not properly set up.

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