(bug report & work-around) exception on c++ :ProjectCreate

40 views
Skip to first unread message

Johnny Graettinger

unread,
Sep 24, 2011, 3:21:20 PM9/24/11
to eclim-user
Howdy,

Documenting steps for replication:

* Downloaded a clean install of "Eclipse IDE for C/C++ Linux
Developers (includes Incubating components)", version 3.7.1; unpacked
in home directory
* Installed eclim 1.7.2, with the C++ feature. The installer didn't
ask me to update any third-party components.
* Started ~/eclipse/eclipse -clean, selected ~/workspace as default
workspace
* Started vim
* :ProjectCreate ~/home/workspace/test -n c++

In the terminal running eclipse, I get the following stacktrace:

2011-09-24 15:04:12,741 INFO
[org.eclim.eclipse.AbstractEclimApplication] Eclim Server Started on:
127.0.0.1:9091
java.lang.ExceptionInInitializerError
at
org.eclipse.cdt.managedbuilder.ui.wizards.CDTConfigWizardPage.<clinit>(CDTConfigWizardPage.java:
60)
at
org.eclipse.cdt.managedbuilder.ui.wizards.MBSWizardHandler.getConfigPage(MBSWizardHandler.java:
625)
at
org.eclipse.cdt.managedbuilder.ui.wizards.MBSWizardHandler.getCfgItems(MBSWizardHandler.java:
718)
at org.eclim.plugin.cdt.project.CProjectManager
$LocalMBSWizardHandler.getCfgItems(CProjectManager.java:306)
at
org.eclipse.cdt.managedbuilder.ui.wizards.MBSWizardHandler.setProjectDescription(MBSWizardHandler.java:
556)
at
org.eclipse.cdt.managedbuilder.ui.wizards.MBSWizardHandler.createProject(MBSWizardHandler.java:
537)
at
org.eclim.plugin.cdt.project.CProjectManager.create(CProjectManager.java:
157)
at
org.eclim.plugin.core.project.ProjectManagement.create(ProjectManagement.java:
171)
at
org.eclim.plugin.core.command.project.ProjectCreateCommand.execute(ProjectCreateCommand.java:
69)
at org.eclim.command.Main.nailMain(Main.java:92)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at
sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:
57)
at
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:
43)
at java.lang.reflect.Method.invoke(Method.java:616)
at com.martiansoftware.nailgun.NGSession.run(NGSession.java:336)
Caused by: java.lang.NullPointerException
at
org.eclipse.jface.resource.JFaceResources.getResources(JFaceResources.java:
207)
at org.eclipse.jface.resource.ImageRegistry.<init>(ImageRegistry.java:
152)
at org.eclipse.jface.resource.ImageRegistry.<init>(ImageRegistry.java:
124)
at
org.eclipse.cdt.managedbuilder.ui.properties.ManagedBuilderUIImages.<clinit>(ManagedBuilderUIImages.java:
32)
... 15 more

* Without restarting eclipse, if I attempt a "File => New => C++
Project", I see the following error logged:

Cannot create ICProjectTypeHandler: Plug-in
"org.eclipse.cdt.managedbuilder.ui" was unable to instantiate class
"org.eclipse.cdt.managedbuilder.ui.wizards.ManagedBuildWizard".


Workaround:

* Start eclipse, issue "File => New => C++ Project"; the wizard window
opens; close it
* Now issue :ProjectCreate from vim; success

cheers,
-johnny

Eric Van Dewoestine

unread,
Sep 26, 2011, 10:13:51 AM9/26/11
to eclim...@googlegroups.com

Thank you for the well described issue report! I'll dig into this when
I get a chance.

--
eric

Eric Van Dewoestine

unread,
Oct 2, 2011, 7:48:07 PM10/2/11
to eclim...@googlegroups.com
On 2011-09-24 12:21:20, Johnny Graettinger wrote:
> Howdy,
>
> Documenting steps for replication:
>
> * Downloaded a clean install of "Eclipse IDE for C/C++ Linux
> Developers (includes Incubating components)", version 3.7.1; unpacked
> in home directory
> * Installed eclim 1.7.2, with the C++ feature. The installer didn't
> ask me to update any third-party components.
> * Started ~/eclipse/eclipse -clean, selected ~/workspace as default
> workspace
> * Started vim
> * :ProjectCreate ~/home/workspace/test -n c++
>
> In the terminal running eclipse, I get the following stacktrace:
> ...

> * Without restarting eclipse, if I attempt a "File => New => C++
> Project", I see the following error logged:
>
> Cannot create ICProjectTypeHandler: Plug-in
> "org.eclipse.cdt.managedbuilder.ui" was unable to instantiate class
> "org.eclipse.cdt.managedbuilder.ui.wizards.ManagedBuildWizard".
>
>
> Workaround:
>
> * Start eclipse, issue "File => New => C++ Project"; the wizard window
> opens; close it
> * Now issue :ProjectCreate from vim; success
>
> cheers,
> -johnny

Thanks again for the bug report. I checked in a change[1] which fixes
the issue for me. If you get chance can you build eclim from the
master branch and ensure that the problem is now resolved for you?

[1] https://github.com/ervandew/eclim/commit/393e998d9e70f8a5673d2286a6e3780d8f82affe

--
eric

Johnny Graettinger

unread,
Oct 3, 2011, 10:26:03 PM10/3/11
to eclim...@googlegroups.com
Hey Eric,

I'm trying to build HEAD on master via "ant dist"; I've worked out build dependencies such that the various eclim plugins compile & python documentation utils run. There was a build step wanting to execute "${env.FORMIC_HOME}/bin/formic". I cloned that from your github, built it via "ant dist", and pointed my environment at the resulting build layout via:

export FORMIC_HOME=/home/johng/formic/build/temp/formic

I'm now getting the following build error, which has me at a bit of a loss:

     [exec] ------ installer.feature
     [exec]      [copy] Copying 1 file to /home/johng/eclim/build/temp/installer/formic
     [exec] [formic:package] Building installer jar...
     [exec] [formic:package] Copying 1 file to /home/johng/eclim/build/temp/installer/formic
     [exec] 
     [exec] BUILD FAILED
     [exec] /home/johng/eclim/org.eclim.installer/build/build.xml:78: java.lang.IllegalAccessError: tried to access method org.apache.tools.ant.types.ZipFileSet.<init>(Lorg/apache/tools/ant/types/FileSet;)V from class org.formic.ant.PackageTask
     [exec] at org.formic.ant.PackageTask.execute(PackageTask.java:94)
     [exec] at org.apache.tools.ant.UnknownElement.execute(UnknownElement.java:291)
     [exec] at sun.reflect.GeneratedMethodAccessor4.invoke(Unknown Source)
     [exec] at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
     [exec] at java.lang.reflect.Method.invoke(Method.java:616)
     [exec] at org.apache.tools.ant.dispatch.DispatchUtils.execute(DispatchUtils.java:106)
     [exec] at org.apache.tools.ant.Task.perform(Task.java:348)
     [exec] at org.apache.tools.ant.Target.execute(Target.java:390)
     [exec] at org.apache.tools.ant.Target.performTasks(Target.java:411)
     [exec] at org.apache.tools.ant.Project.executeSortedTargets(Project.java:1399)
     [exec] at org.apache.tools.ant.Project.executeTarget(Project.java:1368)
     [exec] at org.apache.tools.ant.helper.DefaultExecutor.executeTargets(DefaultExecutor.java:41)
     [exec] at org.apache.tools.ant.Project.executeTargets(Project.java:1251)
     [exec] at org.apache.tools.ant.Main.runBuild(Main.java:809)
     [exec] at org.apache.tools.ant.Main.startAnt(Main.java:217)
     [exec] at org.apache.tools.ant.launch.Launcher.run(Launcher.java:280)
     [exec] at org.apache.tools.ant.launch.Launcher.main(Launcher.java:109)
     [exec] 
     [exec] Total time: 4 seconds

If that's ringing any bells I'm happy to dig a bit further, or if you can provide a prepackaged jar of HEAD I'll try that.

thx,
johnny



--
You received this message because you are subscribed to the Google Groups "eclim-user" group.
To post to this group, send email to eclim...@googlegroups.com.
To unsubscribe from this group, send email to eclim-user+...@googlegroups.com.
For more options, visit this group at http://groups.google.com/group/eclim-user?hl=en.


Eric Van Dewoestine

unread,
Oct 4, 2011, 12:12:26 AM10/4/11
to eclim...@googlegroups.com

You don't have to use '$ ant dist' unless you really want to build the
eclim installer. To just build and deploy eclim, you can just run
$ ant
(deploy is the default target), with the eclipse home and list of
plugins you want to build as system properties. A more detailed walk
through can be found in the developer guide[1].

[1] http://eclim.org/guides/development.html

--
eric

Johnny Graettinger

unread,
Oct 4, 2011, 12:34:51 AM10/4/11
to eclim...@googlegroups.com
You don't have to use '$ ant dist' unless you really want to build the
eclim installer.

True enough. I can confirm this fixes the issue on my box. Thanks for the quick turnaround.

 
To just build and deploy eclim, you can just run
 $ ant
(deploy is the default target), with the eclipse home and list of
plugins you want to build as system properties. A more detailed walk
through can be found in the developer guide[1].

[1] http://eclim.org/guides/development.html

--
eric

Reply all
Reply to author
Forward
0 new messages