Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.
Bug 325116 - Cannot open the "EPackage Registry" view
Summary: Cannot open the "EPackage Registry" view
Status: CLOSED FIXED
Alias: None
Product: MoDisco
Classification: Modeling
Component: Infrastructure (show other bugs)
Version: 0.8.0   Edit
Hardware: PC Windows XP
: P3 normal (vote)
Target Milestone: 0.8.1   Edit
Assignee: Nicolas Bros CLA
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2010-09-13 10:17 EDT by Gregoire Dupe CLA
Modified: 2011-05-23 09:28 EDT (History)
6 users (show)

See Also:
nicolas.bros: helios+
Kenn.Hussey: pmc_approved+
Ed.Merks: pmc_approved+
gdupe: review+
fabien.giquel: review+


Attachments
patch (862 bytes, patch)
2010-09-13 10:57 EDT, Nicolas Bros CLA
no flags Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Gregoire Dupe CLA 2010-09-13 10:17:51 EDT
Hi,

I’m not able to open the "EPackage Registry" view: I get the following error:

eclipse.buildId=I20100608-0911
java.version=1.6.0_20
java.vendor=Sun Microsystems Inc.
BootLoader constants: OS=win32, ARCH=x86, WS=win32, NL=fr_FR
Command-line arguments:  -os win32 -ws win32 -arch x86


Error
Mon Sep 13 16:08:08 CEST 2010
An internal error occurred during: "Refreshing EPackage Registry View".

java.lang.NoClassDefFoundError: Could not initialize class org.eclipse.gmt.modisco.infra.query.jxpath.JxpathPackage
	at sun.misc.Unsafe.ensureClassInitialized(Native Method)
	at sun.reflect.UnsafeFieldAccessorFactory.newFieldAccessor(Unknown Source)
	at sun.reflect.ReflectionFactory.newFieldAccessor(Unknown Source)
	at java.lang.reflect.Field.acquireFieldAccessor(Unknown Source)
	at java.lang.reflect.Field.getFieldAccessor(Unknown Source)
	at java.lang.reflect.Field.get(Unknown Source)
	at org.eclipse.emf.ecore.plugin.RegistryReader$EPackageDescriptor.getEPackage(RegistryReader.java:274)
	at org.eclipse.emf.ecore.impl.EPackageImpl$1.getEPackage(EPackageImpl.java:168)
	at org.eclipse.emf.ecore.impl.EPackageRegistryImpl.getEPackage(EPackageRegistryImpl.java:133)
	at org.eclipse.gmt.modisco.infra.common.ui.internal.views.PackageRegistryView.preloadRegistry(PackageRegistryView.java:168)
	at org.eclipse.gmt.modisco.infra.common.ui.internal.views.PackageRegistryView.doRefresh(PackageRegistryView.java:299)
	at org.eclipse.gmt.modisco.infra.common.ui.internal.views.AbstractCatalogView$5.run(AbstractCatalogView.java:182)
	at org.eclipse.core.internal.jobs.Worker.run(Worker.java:54)

Regards,
Grégoire
Comment 1 Nicolas Bros CLA 2010-09-13 10:41:31 EDT
I got almost the same exception, but with "UnsupportedClassVersionError", because I had compiled with Java 6 and run with Java 5.
Comment 2 Nicolas Bros CLA 2010-09-13 10:57:36 EDT
Created attachment 178747 [details]
patch

Here is a patch that catches the exceptions and logs them, so that one single EPackage failing to load doesn't crash the whole view.
Comment 3 Nicolas Bros CLA 2010-09-13 10:59:46 EDT
I committed this on trunk (revision 3024). Should this be applied to branch 0.8 as well?
Comment 4 Gregoire Dupe CLA 2010-09-13 11:53:40 EDT
Hi,

I think that this patch should be applied to branch 0.8.

Regards,
Grégoire
Comment 5 Kenn Hussey CLA 2010-09-14 08:59:08 EDT
Note that, technically, PMC approval is not required to fix issues in a service release (although, depending on the nature of the issue/fix, it's not necessarily a bad idea)...
Comment 6 Nicolas Bros CLA 2010-09-14 09:15:28 EDT
Thank you.

I have committed the patch on branch 0.8 (revision 3044).
Comment 7 Hugo Bruneliere CLA 2010-10-05 05:07:51 EDT
The patch has been successfully applied.