Bug 875490 - eclipse with ADT: Class org.eclipse.wst.xml.core.internal.document.DocumentImpl does not implement the requested interface org.w3c.dom.Document
Summary: eclipse with ADT: Class org.eclipse.wst.xml.core.internal.document.DocumentIm...
Keywords:
Status: CLOSED CURRENTRELEASE
Alias: None
Product: Fedora
Classification: Fedora
Component: eclipse
Version: 18
Hardware: All
OS: Linux
unspecified
medium
Target Milestone: ---
Assignee: Krzysztof Daniel
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2012-11-11 16:08 UTC by John Ruemker
Modified: 2014-01-13 00:27 UTC (History)
13 users (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2013-01-12 00:05:53 UTC
Type: Bug
Embargoed:


Attachments (Terms of Use)
/usr/lib64/eclipse/configuration/org.eclipse.equinox.simpleconfigurator/bundles.info (21.78 KB, application/octet-stream)
2012-12-17 20:03 UTC, John Ruemker
no flags Details
~/.eclipse/org.eclipse.platform_4.2.0_793567567/configuration/org.eclipse.equinox.simpleconfigurator/bundles.info (31.01 KB, application/octet-stream)
2012-12-17 20:10 UTC, John Ruemker
no flags Details
eclipse -debug -consolelog (13.78 KB, application/octet-stream)
2012-12-17 20:12 UTC, John Ruemker
no flags Details
eclipse -clean -debug -consolelog (6.92 KB, application/octet-stream)
2012-12-17 20:13 UTC, John Ruemker
no flags Details
eclipse -debug -consolelog (74.86 KB, application/octet-stream)
2012-12-18 14:32 UTC, John Ruemker
no flags Details

Description John Ruemker 2012-11-11 16:08:46 UTC
Description of problem: Creating a new bug in response to https://bugzilla.redhat.com/show_bug.cgi?id=851335#c33:

>> This bug needs to be forked because there is still a remaining issue:
>> Class org.eclipse.wst.xml.core.internal.document.DocumentImpl does not implement the requested interface org.w3c.dom.Document


Version-Release number of selected component (if applicable): eclipse-platform-4.2.1-1.fc18.x86_64


How reproducible: Easily reproduceable


Steps to Reproduce:
1. Install ADT in eclipse
2. Create android project
3. Save files
  
Actual results: Error dialog with details:

>> An internal error occurred during: "Running Android Lint".
>> Class org.eclipse.wst.xml.core.internal.document.DocumentImpl does not implement the requested interface org.w3c.dom.Document


Expected results: No errors


Additional info:

Comment 1 Ben Boeckel 2012-12-06 07:20:17 UTC
Ping?

Comment 2 Krzysztof Daniel 2012-12-06 07:49:57 UTC
I have tested with latest Eclipse (4.2.1-21.fc18.x86_64) and it works fine for me. Could you try to reproduce the issue?

Comment 3 Ben Boeckel 2012-12-06 07:58:08 UTC
I'm using eclipse-platform-4.2.1-21.fc19.x86_64 . Up-to-date as of today.

Comment 4 Krzysztof Daniel 2012-12-06 08:01:13 UTC
and which version of xerces-j2?

Comment 5 Ben Boeckel 2012-12-06 08:08:33 UTC
xerces-j2-2.11.0-9.fc19.noarch

Comment 6 Daniel Rindt 2012-12-10 11:45:29 UTC
Installed eclipse-platform-4.2.1-21.fc18.x86_64 and i am unnable to create a android project. The other already mentiones misbehaviour still persisting.

Comment 7 Daniel Rindt 2012-12-10 12:07:31 UTC
Is there yet a known workaround?

Comment 8 Fedora Update System 2012-12-12 08:59:36 UTC
xerces-j2-2.11.0-10.fc18 has been submitted as an update for Fedora 18.
https://admin.fedoraproject.org/updates/FEDORA-2012-20169/xerces-j2-2.11.0-10.fc18

Comment 9 John Ruemker 2012-12-13 20:17:02 UTC
Even with the xerces-j2-2.11.0-10.fc18 from Comment #8, Android does not seem to be loading the ADT plugin.  I've cleared out my workspace and ~/.eclipse, start eclipse, use Help->Install New Software... to install the plugin, it installs with no errors and prompts me to restart, and after I do, none of the ADT features are available.  Can't create an android project, there is no Android section under Preferences, and if I import an existing project none of it shows up properly like it used to.

xerces-j2-2.11.0-10.fc18.noarch
eclipse-equinox-osgi-4.2.1-21.fc18.x86_64
eclipse-ecf-core-3.5.6-3.fc18.noarch
eclipse-pde-4.2.1-21.fc18.x86_64
eclipse-jdt-4.2.1-21.fc18.x86_64
eclipse-emf-core-2.8.1-3.fc18.noarch
eclipse-swt-4.2.1-21.fc18.x86_64
eclipse-platform-4.2.1-21.fc18.x86_64
icu4j-eclipse-4.4.2.2-12.fc18.noarch

Running the downloaded version from eclipse.org works fine. 

I can't say this is specifically related to this bugzilla, but given the ADT plugin doesn't even load for me to confirm the new xerces-j2 package fixes the originally reported issue, I decided to post here. 

-John

Comment 10 Fedora Update System 2012-12-17 09:31:18 UTC
xerces-j2-2.11.0-11.fc18 has been submitted as an update for Fedora 18.
https://admin.fedoraproject.org/updates/xerces-j2-2.11.0-11.fc18

Comment 11 John Ruemker 2012-12-17 14:53:10 UTC
FWIW, same issue from comment #9 still exists with the new xerces-j2 package.

$ rpm -qa | grep -e eclipse -e xerces
eclipse-emf-core-2.8.1-3.fc18.noarch
eclipse-jdt-4.2.1-21.fc18.x86_64
eclipse-equinox-osgi-4.2.1-21.fc18.x86_64
eclipse-ecf-core-3.5.6-3.fc18.noarch
eclipse-pde-4.2.1-21.fc18.x86_64
icu4j-eclipse-4.4.2.2-12.fc18.noarch
eclipse-platform-4.2.1-21.fc18.x86_64
xerces-j2-2.11.0-11.fc18.noarch
eclipse-swt-4.2.1-21.fc18.x86_64

Also note I don't get any errors in the terminal I run eclipse from.  If there is a log somewhere that might shed some more light on what's happening, or anything else you'd like me to do to gather more info, just let me know.

Thanks,
John

Comment 12 Fedora Update System 2012-12-17 18:29:55 UTC
Package xerces-j2-2.11.0-11.fc18:
* should fix your issue,
* was pushed to the Fedora 18 testing repository,
* should be available at your local mirror within two days.
Update it with:
# su -c 'yum update --enablerepo=updates-testing xerces-j2-2.11.0-11.fc18'
as soon as you are able to.
Please go to the following url:
https://admin.fedoraproject.org/updates/FEDORA-2012-20513/xerces-j2-2.11.0-11.fc18
then log in and leave karma (feedback).

Comment 13 Krzysztof Daniel 2012-12-17 19:05:06 UTC
(In reply to comment #11)
> FWIW, same issue from comment #9 still exists with the new xerces-j2 package.
John,
just to double check - do you run eclipse with -clean or delete the ~/.eclipse folder?

Comment 14 John Ruemker 2012-12-17 19:06:03 UTC
I've been deleting ~/.eclipse.

Comment 15 Krzysztof Daniel 2012-12-17 19:35:23 UTC
John, 

I need you to:

1. upload your bundles.info file that is in the /usr/lib64/eclipse/configuration/org.eclipse.equinox.simpleconfigurator/

2. upload your bundles.info file that is created after start in ~/.eclipse (deep buried in org.eclipse.equinox.simpleconfigurator folder).


Run eclipse using the command:
eclipse -debug -consolelog
and
eclipse -clean -debug -consolelog
and gather output.

Comment 16 John Ruemker 2012-12-17 20:03:50 UTC
Created attachment 665090 [details]
/usr/lib64/eclipse/configuration/org.eclipse.equinox.simpleconfigurator/bundles.info

Comment 17 John Ruemker 2012-12-17 20:10:01 UTC
Created attachment 665093 [details]
~/.eclipse/org.eclipse.platform_4.2.0_793567567/configuration/org.eclipse.equinox.simpleconfigurator/bundles.info

Comment 18 John Ruemker 2012-12-17 20:12:20 UTC
Created attachment 665094 [details]
eclipse -debug -consolelog

Comment 19 John Ruemker 2012-12-17 20:13:49 UTC
Created attachment 665095 [details]
eclipse -clean -debug -consolelog

Comment 20 John Ruemker 2012-12-17 20:25:07 UTC
Data uploaded.  The debug output does show some warnings about missing bundles.  Not sure if that's something I've missed installing, or if they're relevant to the problem at hand though. 

-John

Comment 21 Samuel Sieb 2012-12-17 23:47:04 UTC
With xerces-j2-2.11.0-11.fc18, Android lint works for me.

Comment 22 Krzysztof Daniel 2012-12-18 13:28:54 UTC
John, 

It looks like this is the most significant error:

!SUBENTRY 2 org.eclipse.equinox.jsp.jasper 2 0 2012-12-17 14:49:48.742
!MESSAGE Missing imported package org.apache.jasper.servlet_[0.0.0,6.0.0).

The package org.apache.jasper.servlet is provided by the glassfish-jsp package. Could you check if you have it installed, if yes, than in which version (it must be the same version that was used to build eclipse - glassfish-jsp-2.2.5-*

you check where eclipse points by 
ls -l /usr/lib64/eclipse/plugins | grep org.glassfish.web.javax.servlet.jsp

Comment 23 John Ruemker 2012-12-18 14:30:53 UTC
That was indeed the cause of my latest troubles :/  When I had first run into the problem this bug was opened for, I had updated to the rawhide eclipse to test if it was any better, and I guess that pulled in a later glassfish-jsp, which I never reverted.  After fixing that, the ADT plugin does now load.

That said, the original issue still exists for me.  I can import my android project without issue, but as soon as I pull up any of my layout resource files, I get an error dialog with 2 errors:

1) The one initially reported in this bug:

There was a problem adding adapter factories
Class org.eclipse.wst.xml.core.internal.document.DocumentImpl does not implement the requested interface org.w3c.dom.Document

2) A NullPointerException:

An error has occurred. See error log for more details.
java.lang.NullPointerException



$ rpm -qa | grep -e eclipse -e xerces-j2 -e glassfish-jsp
eclipse-equinox-osgi-4.2.1-21.fc18.x86_64
eclipse-ecf-core-3.5.6-3.fc18.noarch
eclipse-pde-4.2.1-21.fc18.x86_64
eclipse-emf-core-2.8.1-3.fc18.noarch
eclipse-jdt-4.2.1-21.fc18.x86_64
eclipse-platform-4.2.1-21.fc18.x86_64
glassfish-jsp-2.2.5-2.fc18.noarch
eclipse-swt-4.2.1-21.fc18.x86_64
icu4j-eclipse-4.4.2.2-12.fc18.noarch
glassfish-jsp-api-2.2.1-4.fc18.noarch
xerces-j2-2.11.0-11.fc18.noarch
$ ls ~/.eclipse
ls: cannot access /home/jruemker/.eclipse: No such file or directory
$ ls ~/workspace/eclipse
ls: cannot access /home/jruemker/workspace/eclipse: No such file or directory
$ eclipse -debug -consolelog
[...]

I'll attach the debug output. 



-John

Comment 24 John Ruemker 2012-12-18 14:32:16 UTC
Created attachment 665537 [details]
eclipse -debug -consolelog

Comment 25 Krzysztof Daniel 2012-12-19 07:45:48 UTC
John,
I think we are finally there - install eclipse-dtp, reinstall ADT and verify it works.

The problem is that xerces-j2 must be installed into the eclipse - that's the details I have missed because I always install the full Eclipse stack - so it was working for me.

I'm afraid that this fix cannot be made permament - introducing a new dependency to Eclipse platform is not welcome :-(. Once you confirm it works for you - I'll write a blog post.

I'm afraid that the only solution here is to package ADT into Fedora.

Comment 26 John Ruemker 2012-12-19 14:49:09 UTC
Success!  Everything's working after that.  Sorry for all the troubles; I see now that its probably better to install the "Fedora Eclipse" group rather than just "yum install eclipse" so that it pulls in all of the important packages.  

Thanks so much for all your help.

-John

Comment 27 Andrew Overholt 2012-12-19 15:43:37 UTC
(In reply to comment #25)
> I think we are finally there - install eclipse-dtp, reinstall ADT and verify
> it works.

Awesome!  This has been a long time coming.  Thanks for the hard work and perseverance, Chris and others.

Comment 28 Jason Farrell 2013-01-11 17:28:31 UTC
Thanks! After installing eclipse-dtp I'm back up and running with ADT.

The mistake I made was installing just eclipse with basic deps, instead of yum installing the @eclipse group which includes eclipse-dtp and others by default.

Comment 29 Fedora Update System 2013-01-12 00:05:56 UTC
xerces-j2-2.11.0-11.fc18 has been pushed to the Fedora 18 stable repository.  If problems still persist, please make note of it in this bug report.


Note You need to log in before you can comment on or make changes to this bug.