java.lang.IllegalArgumentException

There are no available Samebug tips for this exception. Do you have an idea how to solve this issue? A short tip would help users who saw this issue last week.

  • Creation of a new Groovy Class (can be a Script type too) fails in STS 3.6.0 when the Groovy+Gradle project has "crash.shell" as a dependency. Once the error dialog is dismissed, the Groovy Class exists in the workspace, but you cannot right-click and choose "Run As". There is no popup menu. If you remove "crash.shell" as a dependency from the build.gradle file, and Refresh Dependencies on the project from the Gradle menu, the ability to "Run As" returns. Here is the stack trace from the STS log file: Root exception: java.lang.IllegalArgumentException at org.eclipse.jdt.core.dom.ASTNode.setSourceRange(ASTNode.java:2845) at org.eclipse.jdt.core.dom.ASTConverter.convertImport(ASTConverter.java:3151) at org.eclipse.jdt.core.dom.ASTConverter.convert(ASTConverter.java:1430) at org.eclipse.jdt.core.dom.CompilationUnitResolver.convert(CompilationUnitResolver.java:295) at org.eclipse.jdt.core.dom.ASTParser.internalCreateAST(ASTParser.java:1209) at org.eclipse.jdt.core.dom.ASTParser.createAST(ASTParser.java:809) at org.eclipse.jdt.ui.wizards.NewTypeWizardPage.createASTForImports(NewTypeWizardPage.java:2251) at org.eclipse.jdt.ui.wizards.NewTypeWizardPage.createType(NewTypeWizardPage.java:2117) at org.codehaus.groovy.eclipse.wizards.NewClassWizardPage.createType(NewClassWizardPage.java:164) at org.codehaus.groovy.eclipse.wizards.NewClassWizard.finishPage(NewClassWizard.java:64) at org.eclipse.jdt.internal.ui.wizards.NewElementWizard$2.run(NewElementWizard.java:118) at org.eclipse.jdt.internal.core.BatchOperation.executeOperation(BatchOperation.java:39) at org.eclipse.jdt.internal.core.JavaModelOperation.run(JavaModelOperation.java:729) at org.eclipse.core.internal.resources.Workspace.run(Workspace.java:2313) at org.eclipse.jdt.core.JavaCore.run(JavaCore.java:5358) at org.eclipse.jdt.internal.ui.actions.WorkbenchRunnableAdapter.run(WorkbenchRunnableAdapter.java:106) at org.eclipse.jface.operation.ModalContext$ModalContextThread.run(ModalContext.java:122)
    via by Adam Harris,
  • Creation of a new Groovy Class (can be a Script type too) fails in STS 3.6.0 when the Groovy+Gradle project has "crash.shell" as a dependency. Once the error dialog is dismissed, the Groovy Class exists in the workspace, but you cannot right-click and choose "Run As". There is no popup menu. If you remove "crash.shell" as a dependency from the build.gradle file, and Refresh Dependencies on the project from the Gradle menu, the ability to "Run As" returns. Here is the stack trace from the STS log file: Root exception: java.lang.IllegalArgumentException at org.eclipse.jdt.core.dom.ASTNode.setSourceRange(ASTNode.java:2845) at org.eclipse.jdt.core.dom.ASTConverter.convertImport(ASTConverter.java:3151) at org.eclipse.jdt.core.dom.ASTConverter.convert(ASTConverter.java:1430) at org.eclipse.jdt.core.dom.CompilationUnitResolver.convert(CompilationUnitResolver.java:295) at org.eclipse.jdt.core.dom.ASTParser.internalCreateAST(ASTParser.java:1209) at org.eclipse.jdt.core.dom.ASTParser.createAST(ASTParser.java:809) at org.eclipse.jdt.ui.wizards.NewTypeWizardPage.createASTForImports(NewTypeWizardPage.java:2251) at org.eclipse.jdt.ui.wizards.NewTypeWizardPage.createType(NewTypeWizardPage.java:2117) at org.codehaus.groovy.eclipse.wizards.NewClassWizardPage.createType(NewClassWizardPage.java:164) at org.codehaus.groovy.eclipse.wizards.NewClassWizard.finishPage(NewClassWizard.java:64) at org.eclipse.jdt.internal.ui.wizards.NewElementWizard$2.run(NewElementWizard.java:118) at org.eclipse.jdt.internal.core.BatchOperation.executeOperation(BatchOperation.java:39) at org.eclipse.jdt.internal.core.JavaModelOperation.run(JavaModelOperation.java:729) at org.eclipse.core.internal.resources.Workspace.run(Workspace.java:2313) at org.eclipse.jdt.core.JavaCore.run(JavaCore.java:5358) at org.eclipse.jdt.internal.ui.actions.WorkbenchRunnableAdapter.run(WorkbenchRunnableAdapter.java:106) at org.eclipse.jface.operation.ModalContext$ModalContextThread.run(ModalContext.java:122)
    via by Adam Harris,
  • I've installed GGT using archived update site springsource-tool-suite-3.5.0.RELEASE-e4.3.2-updatesite.zip and this version of eclipse eclipse-jee-kepler-SR2-win32-x86_64.zip. When I try to create groovy project based on existing project I receve this exception: {code} !ENTRY org.eclipse.jdt.ui 4 0 2014-04-10 10:32:05.633 !MESSAGE Error in JDT Core during AST creation !STACK 0 java.lang.IllegalArgumentException at org.eclipse.jdt.core.dom.ASTNode.setSourceRange(ASTNode.java:2845) at org.eclipse.jdt.core.dom.ASTConverter.setTypeAnnotationsAndSourceRangeOnArray(ASTConverter.java:3488) at org.eclipse.jdt.core.dom.ASTConverter.convertToArray(ASTConverter.java:3234) at org.eclipse.jdt.core.dom.ASTConverter.convertType(ASTConverter.java:3696) at org.eclipse.jdt.core.dom.ASTConverter.convert(ASTConverter.java:618) at org.eclipse.jdt.core.dom.ASTConverter.buildBodyDeclarations(ASTConverter.java:207) at org.eclipse.jdt.core.dom.ASTConverter.convert(ASTConverter.java:3026) at org.eclipse.jdt.core.dom.ASTConverter.convert(ASTConverter.java:1442) at org.eclipse.jdt.core.dom.CompilationUnitResolver.convert(CompilationUnitResolver.java:295) at org.eclipse.jdt.core.dom.ASTParser.internalCreateAST(ASTParser.java:1209) at org.eclipse.jdt.core.dom.ASTParser.createAST(ASTParser.java:809) at org.eclipse.jdt.internal.ui.javaeditor.ASTProvider$1.run(ASTProvider.java:544) at org.eclipse.core.runtime.SafeRunner.run(SafeRunner.java:42) at org.eclipse.jdt.internal.ui.javaeditor.ASTProvider.createAST(ASTProvider.java:537) at org.eclipse.jdt.internal.ui.javaeditor.ASTProvider.getAST(ASTProvider.java:480) at org.eclipse.jdt.ui.SharedASTProvider.getAST(SharedASTProvider.java:128) at org.eclipse.jdt.internal.ui.viewsupport.SelectionListenerWithASTManager$PartListenerGroup.calculateASTandInform(SelectionListenerWithASTManager.java:170) at org.eclipse.jdt.internal.ui.viewsupport.SelectionListenerWithASTManager$PartListenerGroup$3.run(SelectionListenerWithASTManager.java:155) at org.eclipse.core.internal.jobs.Worker.run(Worker.java:53) {code} and several NPEs. See full stack tarce in the attached file.
    via by Oleg Kedrov,
  • I've installed GGT using archived update site springsource-tool-suite-3.5.0.RELEASE-e4.3.2-updatesite.zip and this version of eclipse eclipse-jee-kepler-SR2-win32-x86_64.zip. When I try to create groovy project based on existing project I receve this exception: {code} !ENTRY org.eclipse.jdt.ui 4 0 2014-04-10 10:32:05.633 !MESSAGE Error in JDT Core during AST creation !STACK 0 java.lang.IllegalArgumentException at org.eclipse.jdt.core.dom.ASTNode.setSourceRange(ASTNode.java:2845) at org.eclipse.jdt.core.dom.ASTConverter.setTypeAnnotationsAndSourceRangeOnArray(ASTConverter.java:3488) at org.eclipse.jdt.core.dom.ASTConverter.convertToArray(ASTConverter.java:3234) at org.eclipse.jdt.core.dom.ASTConverter.convertType(ASTConverter.java:3696) at org.eclipse.jdt.core.dom.ASTConverter.convert(ASTConverter.java:618) at org.eclipse.jdt.core.dom.ASTConverter.buildBodyDeclarations(ASTConverter.java:207) at org.eclipse.jdt.core.dom.ASTConverter.convert(ASTConverter.java:3026) at org.eclipse.jdt.core.dom.ASTConverter.convert(ASTConverter.java:1442) at org.eclipse.jdt.core.dom.CompilationUnitResolver.convert(CompilationUnitResolver.java:295) at org.eclipse.jdt.core.dom.ASTParser.internalCreateAST(ASTParser.java:1209) at org.eclipse.jdt.core.dom.ASTParser.createAST(ASTParser.java:809) at org.eclipse.jdt.internal.ui.javaeditor.ASTProvider$1.run(ASTProvider.java:544) at org.eclipse.core.runtime.SafeRunner.run(SafeRunner.java:42) at org.eclipse.jdt.internal.ui.javaeditor.ASTProvider.createAST(ASTProvider.java:537) at org.eclipse.jdt.internal.ui.javaeditor.ASTProvider.getAST(ASTProvider.java:480) at org.eclipse.jdt.ui.SharedASTProvider.getAST(SharedASTProvider.java:128) at org.eclipse.jdt.internal.ui.viewsupport.SelectionListenerWithASTManager$PartListenerGroup.calculateASTandInform(SelectionListenerWithASTManager.java:170) at org.eclipse.jdt.internal.ui.viewsupport.SelectionListenerWithASTManager$PartListenerGroup$3.run(SelectionListenerWithASTManager.java:155) at org.eclipse.core.internal.jobs.Worker.run(Worker.java:53) {code} and several NPEs. See full stack tarce in the attached file.
    via by Oleg Kedrov,
  • Here's an error from the same workspace at the same time: {noformat} java.lang.IllegalArgumentException at org.eclipse.jdt.core.dom.ASTNode.setSourceRange(ASTNode.java:2848) at org.eclipse.jdt.core.dom.ASTConverter.convertType(ASTConverter.java:3681) at org.eclipse.jdt.core.dom.ASTConverter.convert(ASTConverter.java:981) at org.eclipse.jdt.core.dom.ASTConverter.convert(ASTConverter.java:581) at org.eclipse.jdt.core.dom.ASTConverter.buildBodyDeclarations(ASTConverter.java:207) at org.eclipse.jdt.core.dom.ASTConverter.convert(ASTConverter.java:3026) at org.eclipse.jdt.core.dom.ASTConverter.convert(ASTConverter.java:1442) at org.eclipse.jdt.core.dom.CompilationUnitResolver.convert(CompilationUnitResolver.java:295) at org.eclipse.jdt.core.dom.ASTParser.internalCreateAST(ASTParser.java:1209) at org.eclipse.jdt.core.dom.ASTParser.createAST(ASTParser.java:809) at org.eclipse.jdt.internal.junit.launcher.JUnit4TestFinder.internalIsTest(JUnit4TestFinder.java:229) at org.eclipse.jdt.internal.junit.launcher.JUnit4TestFinder.isTest(JUnit4TestFinder.java:197) at org.eclipse.jdt.internal.junit.util.CoreTestSearchEngine.isTestOrTestSuite(CoreTestSearchEngine.java:57) at org.eclipse.jdt.internal.junit.JUnitPropertyTester.isJUnitTest(JUnitPropertyTester.java:119) at org.eclipse.jdt.internal.junit.JUnitPropertyTester.canLaunchAsJUnitTest(JUnitPropertyTester.java:87) at org.eclipse.jdt.internal.junit.JUnitPropertyTester.test(JUnitPropertyTester.java:71) at org.eclipse.core.internal.expressions.Property.test(Property.java:58) at org.eclipse.core.internal.expressions.TestExpression.evaluate(TestExpression.java:99) at org.eclipse.core.internal.expressions.CompositeExpression.evaluateAnd(CompositeExpression.java:53) at org.eclipse.core.internal.expressions.AdaptExpression.evaluate(AdaptExpression.java:106) at org.eclipse.core.internal.expressions.CompositeExpression.evaluateAnd(CompositeExpression.java:53) at org.eclipse.core.internal.expressions.IterateExpression.evaluate(IterateExpression.java:150) at org.eclipse.core.internal.expressions.CompositeExpression.evaluateAnd(CompositeExpression.java:53) at org.eclipse.core.internal.expressions.WithExpression.evaluate(WithExpression.java:72) at org.eclipse.core.internal.expressions.CompositeExpression.evaluateAnd(CompositeExpression.java:53) at org.eclipse.core.internal.expressions.EnablementExpression.evaluate(EnablementExpression.java:53) at org.eclipse.debug.internal.ui.launchConfigurations.LaunchShortcutExtension.evalEnablementExpression(LaunchShortcutExtension.java:287) at org.eclipse.debug.internal.ui.contextlaunching.LaunchingResourceManager.getShortcutsForSelection(LaunchingResourceManager.java:456) at org.eclipse.debug.internal.ui.contextlaunching.LaunchingResourceManager.computeLabels(LaunchingResourceManager.java:236) at org.eclipse.debug.internal.ui.contextlaunching.LaunchingResourceManager$2.run(LaunchingResourceManager.java:138) at org.eclipse.core.internal.jobs.Worker.run(Worker.java:53) {noformat}
    via by Dave Syer,
    • java.lang.IllegalArgumentException at org.eclipse.jdt.core.dom.ASTNode.setSourceRange(ASTNode.java:2845) at org.eclipse.jdt.core.dom.ASTConverter.convertImport(ASTConverter.java:3151) at org.eclipse.jdt.core.dom.ASTConverter.convert(ASTConverter.java:1430) at org.eclipse.jdt.core.dom.CompilationUnitResolver.convert(CompilationUnitResolver.java:295) at org.eclipse.jdt.core.dom.ASTParser.internalCreateAST(ASTParser.java:1209) at org.eclipse.jdt.core.dom.ASTParser.createAST(ASTParser.java:809) at org.eclipse.jdt.ui.wizards.NewTypeWizardPage.createASTForImports(NewTypeWizardPage.java:2251) at org.eclipse.jdt.ui.wizards.NewTypeWizardPage.createType(NewTypeWizardPage.java:2117) at org.codehaus.groovy.eclipse.wizards.NewClassWizardPage.createType(NewClassWizardPage.java:164) at org.codehaus.groovy.eclipse.wizards.NewClassWizard.finishPage(NewClassWizard.java:64) at org.eclipse.jdt.internal.ui.wizards.NewElementWizard$2.run(NewElementWizard.java:118) at org.eclipse.jdt.internal.core.BatchOperation.executeOperation(BatchOperation.java:39) at org.eclipse.jdt.internal.core.JavaModelOperation.run(JavaModelOperation.java:729) at org.eclipse.core.internal.resources.Workspace.run(Workspace.java:2313) at org.eclipse.jdt.core.JavaCore.run(JavaCore.java:5358) at org.eclipse.jdt.internal.ui.actions.WorkbenchRunnableAdapter.run(WorkbenchRunnableAdapter.java:106) at org.eclipse.jface.operation.ModalContext$ModalContextThread.run(ModalContext.java:122)
    No Bugmate found.