Android Studio beta2 get dagger2 error:
Error:Execution failed for task ':arms:compileDebugJavaWithJavac'.
java.lang.NoClassDefFoundError: dagger/Provides
The same error:
https://github.com/google/dagger/issues/843
Got solution from there(api & implementation):
https://developer.android.com/studio/build/gradle-plugin-3-0-0-migration.html
http://blog.csdn.net/Marvinhq/article/details/73477128
Related
Error: Could not find or load main class org.gradle.wrapper.GradleWrapperMain
Caused by: java.lang.ClassNotFoundException: org.gradle.wrapper.GradleWrapperMain
Exception: Gradle task assembleDebug failed with exit code 1
any help ??
in case someone has the same problem
the problem was with the directory of the project
It was in my main folder which has non English characters
I have been trying to play around with the libgdx framework. I'm following this book called "LibGDX Game development essentials" by Juwal Bose.
The book recommended checking out some game demos libGDX made available. I downloaded this one: github.com/badlogic/theplanethatcouldntflygood.
I tried importing it to eclipse through gradle and during the import preview this message appeared:
Loading Gradle project preview failed due to an error in the referenced Gradle build.
Could not fetch model of type 'GradleBuild' using Gradle distribution 'http://services.gradle.org/distributions/gradle-2.10-all.zip'.
A problem occurred configuring project ':android'.
failed to find target with hash string 'android-20' in: C:\Users\Daniel\android-sdks
Details:
org.gradle.tooling.BuildException: Could not fetch model of type 'GradleBuild' using Gradle distribution 'http://services.gradle.org/distributions/gradle-2.10-all.zip'.
at org.gradle.tooling.internal.consumer.ExceptionTransformer.transform(ExceptionTransformer.java:51)
at org.gradle.tooling.internal.consumer.ExceptionTransformer.transform(ExceptionTransformer.java:29)
at org.gradle.tooling.internal.consumer.ResultHandlerAdapter.onFailure(ResultHandlerAdapter.java:41)
at org.gradle.tooling.internal.consumer.async.DefaultAsyncConsumerActionExecutor$1$1.run(DefaultAsyncConsumerActionExecutor.java:57)
at org.gradle.internal.concurrent.ExecutorPolicy$CatchAndRecordFailures.onExecute(ExecutorPolicy.java:54)
at org.gradle.internal.concurrent.StoppableExecutorImpl$1.run(StoppableExecutorImpl.java:40)
at java.util.concurrent.ThreadPoolExecutor.runWorker(Unknown Source)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(Unknown Source)
at java.lang.Thread.run(Unknown Source)
at org.gradle.tooling.internal.consumer.BlockingResultHandler.getResult(BlockingResultHandler.java:46)
at org.gradle.tooling.internal.consumer.DefaultModelBuilder.get(DefaultModelBuilder.java:51)
at com.gradleware.tooling.toolingclient.internal.DefaultToolingClient.executeAndWait(DefaultToolingClient.java:106)
at com.gradleware.tooling.toolingclient.internal.DefaultModelRequest.executeAndWait(DefaultModelRequest.java:79)
at com.gradleware.tooling.toolingmodel.repository.internal.BaseModelRepository$1.get(BaseModelRepository.java:95)
at com.gradleware.tooling.toolingmodel.repository.internal.BaseModelRepository.executeAndWait(BaseModelRepository.java:163)
at com.gradleware.tooling.toolingmodel.repository.internal.BaseModelRepository.access$000(BaseModelRepository.java:41)
at com.gradleware.tooling.toolingmodel.repository.internal.BaseModelRepository$2.call(BaseModelRepository.java:121)
at com.google.common.cache.LocalCache$LocalManualCache$1.load(LocalCache.java:4724)
at com.google.common.cache.LocalCache$LoadingValueReference.loadFuture(LocalCache.java:3522)
at com.google.common.cache.LocalCache$Segment.loadSync(LocalCache.java:2315)
at com.google.common.cache.LocalCache$Segment.lockedGetOrLoad(LocalCache.java:2278)
at com.google.common.cache.LocalCache$Segment.get(LocalCache.java:2193)
at com.google.common.cache.LocalCache.get(LocalCache.java:3932)
at com.google.common.cache.LocalCache$LocalManualCache.get(LocalCache.java:4721)
at com.gradleware.tooling.toolingmodel.repository.internal.BaseModelRepository.getFromCache(BaseModelRepository.java:138)
at com.gradleware.tooling.toolingmodel.repository.internal.BaseModelRepository.executeRequest(BaseModelRepository.java:117)
at com.gradleware.tooling.toolingmodel.repository.internal.BaseModelRepository.executeRequest(BaseModelRepository.java:88)
at com.gradleware.tooling.toolingmodel.repository.internal.DefaultSingleBuildModelRepository.fetchGradleBuildStructure(DefaultSingleBuildModelRepository.java:132)
at org.eclipse.buildship.core.projectimport.ProjectPreviewJob.fetchGradleBuildStructure(ProjectPreviewJob.java:94)
at org.eclipse.buildship.core.projectimport.ProjectPreviewJob.runToolingApiJobInWorkspace(ProjectPreviewJob.java:83)
at org.eclipse.buildship.core.util.progress.ToolingApiWorkspaceJob$1.run(ToolingApiWorkspaceJob.java:79)
at org.eclipse.buildship.core.util.progress.ToolingApiInvoker.invoke(ToolingApiInvoker.java:63)
at org.eclipse.buildship.core.util.progress.ToolingApiWorkspaceJob.runInWorkspace(ToolingApiWorkspaceJob.java:76)
at org.eclipse.core.internal.resources.InternalWorkspaceJob.run(InternalWorkspaceJob.java:39)
at org.eclipse.core.internal.jobs.Worker.run(Worker.java:55)
Caused by: org.gradle.internal.exceptions.LocationAwareException: A problem occurred configuring project ':android'.
at org.gradle.initialization.DefaultExceptionAnalyser.transform(DefaultExceptionAnalyser.java:74)
at org.gradle.initialization.MultipleBuildFailuresExceptionAnalyser.transform(MultipleBuildFailuresExceptionAnalyser.java:47)
at org.gradle.initialization.StackTraceSanitizingExceptionAnalyser.transform(StackTraceSanitizingExceptionAnalyser.java:30)
at org.gradle.initialization.DefaultGradleLauncher$1.create(DefaultGradleLauncher.java:101)
at org.gradle.initialization.DefaultGradleLauncher$1.create(DefaultGradleLauncher.java:93)
at org.gradle.internal.progress.DefaultBuildOperationExecutor.run(DefaultBuildOperationExecutor.java:90)
at org.gradle.internal.progress.DefaultBuildOperationExecutor.run(DefaultBuildOperationExecutor.java:62)
at org.gradle.initialization.DefaultGradleLauncher.doBuild(DefaultGradleLauncher.java:93)
at org.gradle.initialization.DefaultGradleLauncher.getBuildAnalysis(DefaultGradleLauncher.java:87)
at org.gradle.launcher.exec.InProcessBuildActionExecuter$DefaultBuildController.configure(InProcessBuildActionExecuter.java:102)
at org.gradle.tooling.internal.provider.runner.BuildModelActionRunner.run(BuildModelActionRunner.java:48)
at org.gradle.launcher.exec.ChainingBuildActionRunner.run(ChainingBuildActionRunner.java:35)
at org.gradle.tooling.internal.provider.runner.SubscribableBuildActionRunner.run(SubscribableBuildActionRunner.java:58)
at org.gradle.launcher.exec.ChainingBuildActionRunner.run(ChainingBuildActionRunner.java:35)
at org.gradle.launcher.exec.InProcessBuildActionExecuter.execute(InProcessBuildActionExecuter.java:43)
at org.gradle.launcher.exec.InProcessBuildActionExecuter.execute(InProcessBuildActionExecuter.java:28)
I have put a local.properties file in the root directory of the project indicating the SDK folder. So this is not the problem.
I downloaded version 20 of the Android SDK, with no success.
I have tried reinstalling gradle.
I tried out importing another demo from their git resulting in a very similar error:
Loading Gradle project preview failed due to an error connecting to
the Gradle build. Could not fetch model of type 'GradleBuild' using
Gradle distribution
'services.gradle.org/distributions/gradle-2.2-all.zip'.
A problem occurred configuring project ':android'. failed to find
target with hash string 'android-20' in: C:\Users\Daniel\android-sdks
org.gradle.tooling.GradleConnectionException: Could not fetch model of
type 'GradleBuild' using Gradle distribution
'services.gradle.org/distributions/gradle-2.2-all.zip'.
As suspected, the gradle version in use (2.10) was too old to handle the task, thus upgrading the Eclipse plugin with this link has solved the issue when using gradle with Eclipse.
I am trying to deploy my first GWT application, but I am getting the error below.
I am using jre6, GWT Designer (with GWT DSK 2.5.0), and I have already deleted the gwt-unitCache folder as suggested here:
https://groups.google.com/forum/?fromgroups=#!topic/google-web-toolkit/e3DoVrI6V70
Designer error occurred.
Select Details >> for more information.
See the Error Log for more information.
Reason: Parse error or internal Designer error.
Plug-in Provider: Google
Plug-in Name:
Plug-in ID: org.eclipse
java.lang.NoClassDefFoundError: org/eclipse/jdt/launching/IJavaLaunchConfigurationConstants
at com.google.gdt.eclipse.designer.actions.deploy.DeployModuleAction.getGWTProjectClasspath(DeployModuleAction.java:364)
at
com.google.gdt.eclipse.designer.actions.deploy.DeployModuleAction.createBuildScript(DeployModuleAction.java:150)
at
com.google.gdt.eclipse.designer.actions.deploy.DeployModuleAction.access$1(DeployModuleAction.java:131)
at
com.google.gdt.eclipse.designer.actions.deploy.DeployModuleAction$1.run(DeployModuleAction.java:103)
at
org.eclipse.jface.operation.ModalContext$ModalContextThread.run(ModalContext.java:121)
Full stack trace (to see full context):
java.lang.reflect.InvocationTargetException
at com.google.gdt.eclipse.designer.actions.deploy.DeployModuleAction$1.run(DeployModuleAction.java:114)
at org.eclipse.jface.operation.ModalContext$ModalContextThread.run(ModalContext.java:121)
Caused by: java.lang.NoClassDefFoundError: org/eclipse/jdt/launching/IJavaLaunchConfigurationConstants
at com.google.gdt.eclipse.designer.actions.deploy.DeployModuleAction.getGWTProjectClasspath(DeployModuleAction.java:364)
at com.google.gdt.eclipse.designer.actions.deploy.DeployModuleAction.createBuildScript(DeployModuleAction.java:150)
at com.google.gdt.eclipse.designer.actions.deploy.DeployModuleAction.access$1(DeployModuleAction.java:131)
at com.google.gdt.eclipse.designer.actions.deploy.DeployModuleAction$1.run(DeployModuleAction.java:103)
... 1 more
I am using guava-13.0.jar.
It is included in the classpath.
I am using netbeans Java Free Form Project.
Though I clean-build the project, I am getting the following exception.
Uncaught exception in thread main
java.lang.NoSuchMethodError: com.google.common.collect.Maps.safeGet(Ljava/util/Map;Ljava/lang/Object;)Ljava/lang/Object;
at com.google.common.collect.StandardTable.get(StandardTable.java:117)
at com.google.common.collect.HashBasedTable.get(HashBasedTable.java:135)
Can someone point out how can I fix this error?
I am new to dynamicreports, the example can be found at the link, but it gives me the following exception.
Please help me to find the issue.
Exception in thread "main" java.lang.NoSuchMethodError: net.sf.jasperreports.engine.design.JasperDesign.setIgnorePagination(Z)V
Regards
You must be sure that you are using the correct version of the libraries.
http://dynamicreports.sourceforge.net/requirements.html
In your case you have an error with jasperreports. With DynamicReports 3.0.2, the jasperreports correct version is 4.7.0 or above