[
Date Prev][
Date Next][
Thread Prev][
Thread Next][
Date Index][
Thread Index]
[
List Home]
Re: [tycho-user] javax.persistence class cannot be resolved - It is indirectly referenced from required .class files
|
This also seems to cause the tests to fail:
Jay
!SESSION 2012-06-01 17:03:53.103 -----------------------------------------------
eclipse.buildId=unknown
java.version=1.6.0_22
java.vendor=Sun Microsystems Inc.
BootLoader constants: OS=linux, ARCH=x86_64, WS=gtk, NL=en_US
Framework arguments: -application org.eclipse.tycho.surefire.osgibooter.headlesstest -testproperties /home/bkj/research/NiCE/NiCEWorkspace/gov.ornl.nice.nicedatastructures.test/target/surefire.properties
Command-line arguments: -data /home/bkj/research/NiCE/NiCEWorkspace/gov.ornl.nice.nicedatastructures.test/target/work/data -dev file:/home/bkj/research/NiCE/NiCEWorkspace/gov.ornl.nice.nicedatastructures.test/target/dev.properties -application org.eclipse.tycho.surefire.osgibooter.headlesstest -testproperties /home/bkj/research/NiCE/NiCEWorkspace/gov.ornl.nice.nicedatastructures.test/target/surefire.properties
!ENTRY org.eclipse.osgi 4 0 2012-06-01 17:03:54.285
!MESSAGE Application error
!STACK 1
org.apache.maven.surefire.util.SurefireReflectionException: java.lang.reflect.InvocationTargetException; nested exception is java.lang.reflect.InvocationTargetException: null
java.lang.reflect.InvocationTargetException
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 org.apache.maven.surefire.util.ReflectionUtils.invokeMethodWithArray(ReflectionUtils.java:164)
at org.apache.maven.surefire.booter.ProviderFactory$ProviderProxy.invoke(ProviderFactory.java:110)
at org.apache.maven.surefire.booter.SurefireStarter.invokeProvider(SurefireStarter.java:175)
at org.apache.maven.surefire.booter.SurefireStarter.runSuitesInProcess(SurefireStarter.java:123)
at org.eclipse.tycho.surefire.osgibooter.OsgiSurefireBooter.run(OsgiSurefireBooter.java:84)
at org.eclipse.tycho.surefire.osgibooter.HeadlessTestApplication.run(HeadlessTestApplication.java:21)
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 org.eclipse.equinox.internal.app.EclipseAppContainer.callMethodWithException(EclipseAppContainer.java:587)
at org.eclipse.equinox.internal.app.EclipseAppHandle.run(EclipseAppHandle.java:198)
at org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher.runApplication(EclipseAppLauncher.java:110)
at org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher.start(EclipseAppLauncher.java:79)
at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:353)
at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:180)
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 org.eclipse.equinox.launcher.Main.invokeFramework(Main.java:622)
at org.eclipse.equinox.launcher.Main.basicRun(Main.java:577)
at org.eclipse.equinox.launcher.Main.run(Main.java:1410)
at org.eclipse.equinox.launcher.Main.main(Main.java:1386)
Caused by: java.lang.NullPointerException
at java.lang.Class.getAnnotation(Class.java:3048)
at org.apache.maven.surefire.common.junit4.JUnit4TestChecker.isValidJUnit4Test(JUnit4TestChecker.java:63)
at org.apache.maven.surefire.common.junit4.JUnit4TestChecker.accept(JUnit4TestChecker.java:52)
at org.apache.maven.surefire.util.DefaultDirectoryScanner.locateTestClasses(DefaultDirectoryScanner.java:80)
at org.apache.maven.surefire.junit4.JUnit4Provider.scanClassPath(JUnit4Provider.java:174)
at org.apache.maven.surefire.junit4.JUnit4Provider.invoke(JUnit4Provider.java:83)
... 28 more
On Fri, Jun 1, 2012 at 5:00 PM, Jay Jay Billings
<jayjaybillings@xxxxxxxxx> wrote:
Everyone,
I get the error below when trying to use EclipseLink in an RCP application with Tycho 0.14 -OR- Tycho 0.13. It is resolved by adding javax.persistence to the imported package list of all of my bundles, even those that do not explicitly use it.
I think this is a regression of this bug:
http://dev.eclipse.org/mhonarc/lists/tycho-user/msg00030.html
The DataComponent class mentioned below is annotated with JPA annotations and it is class that is used by almost all of the other bundles. I would expect the dependency to be resolved transitively.
Is there a way to fix this in Tycho?
Jay
-----
[ERROR] Failed to execute goal org.eclipse.tycho:tycho-compiler-plugin:0.14.0:compile (default-compile) on project gov.ornl.nice.niceclient: Compilation failure: Compilation failure:
[ERROR] /home/bkj/research/NiCE/NiCEWorkspace/gov.ornl.nice.niceclient/src/gov/ornl/nice/niceclient/iniceclient/uiwidgets/IExtraInfoWidget.java:[1,0]
[ERROR] package gov.ornl.nice.niceclient.iniceclient.uiwidgets;
[ERROR] ^
[ERROR] The type javax.persistence.CascadeType cannot be resolved. It is indirectly referenced from required .class files
[ERROR] /home/bkj/research/NiCE/NiCEWorkspace/gov.ornl.nice.niceclient/src/gov/ornl/nice/niceclient/iniceclient/uiwidgets/IExtraInfoWidget.java:[1,0]
[ERROR] package gov.ornl.nice.niceclient.iniceclient.uiwidgets;
[ERROR] ^
[ERROR] The type javax.persistence.FetchType cannot be resolved. It is indirectly referenced from required .class files
[ERROR] /home/bkj/research/NiCE/NiCEWorkspace/gov.ornl.nice.niceclient/src/gov/ornl/nice/niceclient/eclipseuiwidgets/NiCEDataComponentSectionPart.java:[92,0]
[ERROR] System.out.println("DataComponent " + dataComp.getName() + ":");
[ERROR] ^^^^^^^^^^^^^^^^^^
[ERROR] The type javax.persistence.GenerationType cannot be resolved. It is indirectly referenced from required .class files
[ERROR] /home/bkj/research/NiCE/NiCEWorkspace/gov.ornl.nice.niceclient/src/gov/ornl/nice/niceclient/eclipseuiwidgets/NiCEDataComponentSectionPart.java:[92,0]
[ERROR] System.out.println("DataComponent " + dataComp.getName() + ":");
[ERROR] ^^^^^^^^^^^^^^^^^^
[ERROR] The type javax.persistence.InheritanceType cannot be resolved. It is indirectly referenced from required .class files
[ERROR] 4 problems (4 errors)
[ERROR] -> [Help 1]