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.

  • It appears that if I group the project directories for an EAR-style Seam project under a subdirectory of my workspace, Eclipse gives the error below. So, my workspace is C:\proj I generated a new Seam 2.0 project, creating: C:\proj\newproj C:\proj\newproj-ear C:\proj\newproj-ejb C:\proj\newproj-test I then put them in another dir (I've got a lot of projects): C:\proj\newproj\newproj C:\proj\newproj\newproj-ear C:\proj\newproj\newproj-ejb C:\proj\newproj\newproj-test Then I imported them and got the error that follows. Note however that the code/debug cycle and deployment to the application server does work. Presumably the impact occurs at time of packing (unconfirmed). Putting the project back into C:\proj resolves this issue, however importing from other directories without copying the files into the workspace is a pretty common way to work AFAIK. Warning Mon Nov 19 14:05:50 MST 2007 Path for project must have only one segment. java.lang.IllegalArgumentException: Path for project must have only one segment. at org.eclipse.core.runtime.Assert.isLegal(Assert.java:62) at org.eclipse.core.internal.resources.WorkspaceRoot.getProject(WorkspaceRoot.java:165) at org.jboss.ide.eclipse.archives.core.model.other.internal.WorkspacePreferenceManager.getResource(WorkspacePreferenceManager.java:54) at org.jboss.ide.eclipse.archives.core.model.other.internal.WorkspacePreferenceManager.isBuilderEnabled(WorkspacePreferenceManager.java:62) at org.jboss.ide.eclipse.archives.core.project.ArchivesBuilder.build(ArchivesBuilder.java:66) at org.eclipse.core.internal.events.BuildManager$2.run(BuildManager.java:624) at org.eclipse.core.runtime.SafeRunner.run(SafeRunner.java:37) at org.eclipse.core.internal.events.BuildManager.basicBuild(BuildManager.java:166) at org.eclipse.core.internal.events.BuildManager.basicBuild(BuildManager.java:197) at org.eclipse.core.internal.events.BuildManager$1.run(BuildManager.java:246) at org.eclipse.core.runtime.SafeRunner.run(SafeRunner.java:37) at org.eclipse.core.internal.events.BuildManager.basicBuild(BuildManager.java:249) at org.eclipse.core.internal.events.BuildManager.basicBuildLoop(BuildManager.java:302) at org.eclipse.core.internal.events.BuildManager.build(BuildManager.java:334) at org.eclipse.core.internal.events.AutoBuildJob.doBuild(AutoBuildJob.java:137) at org.eclipse.core.internal.events.AutoBuildJob.run(AutoBuildJob.java:235) at org.eclipse.core.internal.jobs.Worker.run(Worker.java:55)
    via by Marcus Adair,
  • Steps to reproduce (similar to http://www.jboss.org/community/docs/DOC-10044, "Installing JBoss Tools from the Update Site" section): 1. get Eclipse Platform Runtime Binary (latest 3.4.2 M build, M20090121-1700) 2. use this script to unpack & run in a clean workspace #!/bin/bash eclipse=eclipse-platform-M20090121-1700-linux-gtk.tar.gz workspace=/home/nboldt/eclipse/workspace-clean target=/home/nboldt/eclipse/34clean if [[ $1 ]]; then echo "Wipe $target/eclipse and $workspace ..." rm -fr $target/eclipse $workspace echo "Unpack $eclipse ..." tar xzf $eclipse fi ./eclipse/eclipse -clean -showLocation -data $workspace -consolelog -console -vmargs -Xms128M -Xmx256M \ -XX:PermSize=128M -XX:MaxPermSize=256M 2>&1 | tee "eclipse.log.`date`.txt" 3. Help > Software Updates... > Available Software (tab) > Manage Sites... (button) 4. Add these URLs, or, if they're already listed, make sure they're enabled (checked) o http://download.jboss.org/jbosstools/updates/nightly/trunk/ o http://download.eclipse.org/releases/ganymede/ o http://download.eclipse.org/birt/update-site/2.3/ 5. Click OK. 6. Expand the JBoss Tools Update Site and select any or all of the available features listed thereunder. 7. Click Install... then Next and/or Finish. Restart when prompted. 8. New > JBoss JSF/Seam Portlet > Next. 9. See screenshot. You get this in the console: !ENTRY org.eclipse.jface 4 2 2009-01-23 11:36:21.341 !MESSAGE Problems occurred when invoking code from plug-in: "org.eclipse.jface". !STACK 0 java.lang.IllegalArgumentException: Path for project must have only one segment. at org.eclipse.core.runtime.Assert.isLegal(Assert.java:64) at org.eclipse.core.internal.resources.WorkspaceRoot.getProject(WorkspaceRoot.java:165) at org.eclipse.jem.util.emf.workbench.ProjectUtilities.getProject(ProjectUtilities.java:749) at org.jboss.tools.portlet.ui.internal.wizard.NewJSFPortletClassWizardPage.updateProject(NewJSFPortletClassWizardPage.java:194) at org.jboss.tools.portlet.ui.internal.wizard.NewJSFPortletClassWizardPage.addProjectNameGroup(NewJSFPortletClassWizardPage.java:188) at org.jboss.tools.portlet.ui.internal.wizard.NewJSFPortletClassWizardPage.createTopLevelComposite(NewJSFPortletClassWizardPage.java:93) at org.eclipse.wst.common.frameworks.internal.datamodel.ui.DataModelWizardPage.createControl(DataModelWizardPage.java:103) at org.eclipse.jface.wizard.WizardDialog.updateForPage(WizardDialog.java:1147) at org.eclipse.jface.wizard.WizardDialog.access$2(WizardDialog.java:1139) at org.eclipse.jface.wizard.WizardDialog$4.run(WizardDialog.java:1128) at org.eclipse.swt.custom.BusyIndicator.showWhile(BusyIndicator.java:70) at org.eclipse.jface.wizard.WizardDialog.showPage(WizardDialog.java:1126) at org.eclipse.ui.internal.dialogs.NewWizardSelectionPage.advanceToNextPageOrFinish(NewWizardSelectionPage.java:71) at org.eclipse.ui.internal.dialogs.NewWizardNewPage$1.doubleClick(NewWizardNewPage.java:355) at org.eclipse.jface.viewers.StructuredViewer$1.run(StructuredViewer.java:799) at org.eclipse.core.runtime.SafeRunner.run(SafeRunner.java:37) at org.eclipse.core.runtime.Platform.run(Platform.java:880) at org.eclipse.ui.internal.JFaceUtil$1.run(JFaceUtil.java:48) at org.eclipse.jface.util.SafeRunnable.run(SafeRunnable.java:175) at org.eclipse.jface.viewers.StructuredViewer.fireDoubleClick(StructuredViewer.java:797) at org.eclipse.jface.viewers.AbstractTreeViewer.handleDoubleSelect(AbstractTreeViewer.java:1419) at org.eclipse.jface.viewers.StructuredViewer$4.widgetDefaultSelected(StructuredViewer.java:1173) at org.eclipse.jface.util.OpenStrategy.fireDefaultSelectionEvent(OpenStrategy.java:237) at org.eclipse.jface.util.OpenStrategy.access$0(OpenStrategy.java:234) ...
    via by Nick Boldt,
    • java.lang.IllegalArgumentException: Path for project must have only one segment. at org.eclipse.core.runtime.Assert.isLegal(Assert.java:62) at org.eclipse.core.internal.resources.WorkspaceRoot.getProject(WorkspaceRoot.java:165) at org.jboss.ide.eclipse.archives.core.model.other.internal.WorkspacePreferenceManager.getResource(WorkspacePreferenceManager.java:54) at org.jboss.ide.eclipse.archives.core.model.other.internal.WorkspacePreferenceManager.isBuilderEnabled(WorkspacePreferenceManager.java:62) at org.jboss.ide.eclipse.archives.core.project.ArchivesBuilder.build(ArchivesBuilder.java:66) at org.eclipse.core.internal.events.BuildManager$2.run(BuildManager.java:624) at org.eclipse.core.runtime.SafeRunner.run(SafeRunner.java:37) at org.eclipse.core.internal.events.BuildManager.basicBuild(BuildManager.java:166) at org.eclipse.core.internal.events.BuildManager.basicBuild(BuildManager.java:197) at org.eclipse.core.internal.events.BuildManager$1.run(BuildManager.java:246) at org.eclipse.core.runtime.SafeRunner.run(SafeRunner.java:37) at org.eclipse.core.internal.events.BuildManager.basicBuild(BuildManager.java:249) at org.eclipse.core.internal.events.BuildManager.basicBuildLoop(BuildManager.java:302) at org.eclipse.core.internal.events.BuildManager.build(BuildManager.java:334) at org.eclipse.core.internal.events.AutoBuildJob.doBuild(AutoBuildJob.java:137) at org.eclipse.core.internal.events.AutoBuildJob.run(AutoBuildJob.java:235) at org.eclipse.core.internal.jobs.Worker.run(Worker.java:55)

    Users with the same issue

    Unknown visitor1 times, last one,
    Unknown visitor1 times, last one,
    Unknown visitor1 times, last one,
    Unknown visitor1 times, last one,
    Unknown visitor1 times, last one,
    2 more bugmates