View previous topic :: View next topic |
Author |
Message |
Gust Councilperson
Joined: Oct 09, 2007 Posts: 137
|
Posted: Mon Feb 16, 2009 4:34 pm Post subject: LanguageTool |
|
I've been testing for a while the use of the LanguageTool extension in NeoOffice 3.0 EA 2 and it's quite buggy to say the least. Before I further investigate the matter, I was wondering in how far extension functionality is supported by the NeoOffice community. Generally the line is drawn where improper behaviour is specific to NeoOffice and does not occur in OpenOffice.org, but does this approach extend to extension functionality as well? |
|
Back to top |
|
|
pluby The Architect
Joined: Jun 16, 2003 Posts: 11949
|
Posted: Mon Feb 16, 2009 6:05 pm Post subject: |
|
OpenOffice.org extensions should work fine in NeoOffice as long as they do not try to create their own native windows. LanguageTool, unfortunately, creates its own native Java windows and this really interferes with both NeoOffice and OpenOffice.org's native event handling, menubar management, etc.
LanguageTool has had problems running in both NeoOffice and OpenOffice.org on Mac OS X for a long time and, until they stop creating their own native Java windows, these problems will remain. Apparently, their hacky approach works on Windows and Linux, but Apple's Java on Mac OS X is not the same as Sun Microsystems' Java on Windows and Linux so their is not usable on any Mac OS X OpenOffice.org derivative.
Patrick |
|
Back to top |
|
|
pluby The Architect
Joined: Jun 16, 2003 Posts: 11949
|
Posted: Mon Feb 16, 2009 6:29 pm Post subject: |
|
Gust,
Update: I just downloaded Language Tool version 0.9.6 and that version works specifically with OpenOffice.org 3.0.1 and higher. The old hanging problems that I was referring to in my previous post are no longer applicable to their latest release. Is this the version that you are using? NeoOffice 3.0 Early Access 2 is based on OpenOffice.org 3.0.1.
If you have uninstalled all earlier versions of Language Tool, then installed 0.9.6 and restarted NeoOffice, are you seeing any errors? Language Tool's Configuration and About dialogs work fine. The only error that I see is that a dialog appears when you grammar check with a list of Java errors. Is that what you see? If so, that is probably our error.
Patrick |
|
Back to top |
|
|
pluby The Architect
Joined: Jun 16, 2003 Posts: 11949
|
Posted: Mon Feb 16, 2009 10:36 pm Post subject: |
|
pluby wrote: | Update: I just downloaded Language Tool version 0.9.6 and that version works specifically with OpenOffice.org 3.0.1 and higher. The old hanging problems that I was referring to in my previous post are no longer applicable to their latest release. Is this the version that you are using? NeoOffice 3.0 Early Access 2 is based on OpenOffice.org 3.0.1. |
I found the cause of the error dialog and it was caused by a Java thread setting that need only a very simple fix. With my fix, Language Tool 0.9.6 works surprisingly smoothly in NeoOffice 3.0 Early Access 2. It is pretty clear that the Language Tool developers have made significant changes to their code in recent versions.
Can you try the following test patch and tell us if Language Tool 0.9.6 now works for you?:
Intel:
http://joe.neooffice.org/test/NeoOffice-3.0_Early_Access_2-Patch-1-Test-4-Intel.dmg
PowerPC:
http://joe.neooffice.org/test/NeoOffice-3.0_Early_Access_2-Patch-1-Test-4-PowerPC.dmg
Patrick |
|
Back to top |
|
|
Gust Councilperson
Joined: Oct 09, 2007 Posts: 137
|
Posted: Tue Feb 17, 2009 4:22 am Post subject: |
|
pluby wrote: | I found the cause of the error dialog and it was caused by a Java thread setting that need only a very simple fix. With my fix, Language Tool 0.9.6 works surprisingly smoothly in NeoOffice 3.0 Early Access 2. It is pretty clear that the Language Tool developers have made significant changes to their code in recent versions.
Can you try the following test patch and tell us if Language Tool 0.9.6 now works for you?:
Intel:
http://joe.neooffice.org/test/NeoOffice-3.0_Early_Access_2-Patch-1-Test-4-Intel.dmg | I did some testing and the many LanguageTool error dialogues I get are caused by using more than one language in the same document. You can reproduce this error:- Restart NeoOffice
- In the blank Writer document, type two words on two separate lines (e.g. alfa on the first line and beta on the second)
- Select the word on the second line (beta in our example) and change the language for that word to something else.
I'm using NeoOffice 3.0 EA 2 patch 1 test 4 with LanguageTool 0.9.6. I did a fresh install where I removed all profiles (the prefs folders). Default language is set to Dutch, I use English (US) as the alternative language in the example above.
The error messages invariably say: Code: | An error has occured in Languagetool:
java.lang.NullPointerException
Stacktrace:
morfologik.util.ResourceUtils.getResourceURL(Unknown Source)
morfologik.stemmers.Lametyzator.<init>(Unknown Source)
de.danielnaber.languagetool.tagging.BaseTagger.tag(BaseTagger.java:55)
de.danielnaber.languagetool.JLanguageTool.getAnalyzedSentence(JLanguageTool.java:575)
de.danielnaber.languagetool.JLanguageTool.check(JLanguageTool.java:423)
de.danielnaber.languagetool.openoffice.Main.doGrammarCheckingInterval(Main.java:283)
de.danielnaber.languagetool.openoffice.Main.doProofreading(Main.java:231) | After the error occurs, you should restart NeoOffice before doing any subsequent testing as the error leaves NeoOffice in a state where the error may come back at any arbitrary event. |
|
Back to top |
|
|
pluby The Architect
Joined: Jun 16, 2003 Posts: 11949
|
|
Back to top |
|
|
Gust Councilperson
Joined: Oct 09, 2007 Posts: 137
|
Posted: Tue Feb 17, 2009 11:07 am Post subject: |
|
Downloaded & installed the Intel patch, but it didn't work for me. Still the same error exactly as described in my previous message. |
|
Back to top |
|
|
pluby The Architect
Joined: Jun 16, 2003 Posts: 11949
|
|
Back to top |
|
|
Gust Councilperson
Joined: Oct 09, 2007 Posts: 137
|
Posted: Tue Feb 17, 2009 1:31 pm Post subject: |
|
pluby wrote: | It looks like NeoOffice's underlying OpenOffice.org code is continually creating new threads to run the Language Tool extension in and my fix for bug 2865 is triggering a bug in Apple's Java code that causes the "context class loader" in each Java thread to get unset. The Language Tool code does not expect this value to be unset and then you see the Java error messages dialgo.
I have uploaded another test patch that attempts to fix this bug. Can you try the following test patch and tell us if Language Tool 0.9.6 now works for you?:
Intel:
http://joe.neooffice.org/test/NeoOffice-3.0_Early_Access_2-Patch-1-Test-6-Intel.dmg | Downloaded & tested but unfortunately doesn't work for me. Still the very same error message reported above. |
|
Back to top |
|
|
pluby The Architect
Joined: Jun 16, 2003 Posts: 11949
|
Posted: Tue Feb 17, 2009 1:49 pm Post subject: |
|
Gust wrote: | Downloaded & tested but unfortunately doesn't work for me. Still the very same error message reported above. |
Can you select the Tools :: Options menu in NeoOffice and in the dialog that appears, select the NeoOffice :: Java item and tell us the full version that is selected?
Patrick |
|
Back to top |
|
|
Gust Councilperson
Joined: Oct 09, 2007 Posts: 137
|
Posted: Tue Feb 17, 2009 1:54 pm Post subject: |
|
pluby wrote: | Can you select the Tools :: Options menu in NeoOffice and in the dialog that appears, select the NeoOffice :: Java item and tell us the full version that is selected? | The Java version is 1.5.0_16 (by Apple Inc.), run on a MacBook with an Intel Core Duo processor (i.e. 32 bit addressing version). |
|
Back to top |
|
|
pluby The Architect
Joined: Jun 16, 2003 Posts: 11949
|
Posted: Tue Feb 17, 2009 2:05 pm Post subject: |
|
Gust wrote: | The Java version is 1.5.0_16 (by Apple Inc.), run on a MacBook with an Intel Core Duo processor (i.e. 32 bit addressing version). |
That is the same version as I have been running and I cannot reproduce this with my latest test patch. Can you try the following?:
1. Uninstall Language Tool
2. Reboot your machine
3. Reinstall Patch-1-Test-6 before running NeoOffice
4. Reinstall Language Tool
If the error dialog still appears, can you list the exact steps that you are using? The steps that I have used are:
1. Turn off the automatic spellchecking toolbar button and restart NeoOffice
2. Launch NeoOffice by opening a file that has two lines. The first line is "alfa" and is set to English (USA) and the second line is "beta" and is set to French (French).
3. Turn on the automatic spellchecking toolbar button. No error dialog appears for me with the latest test patch.
Patrick |
|
Back to top |
|
|
Gust Councilperson
Joined: Oct 09, 2007 Posts: 137
|
Posted: Tue Feb 17, 2009 3:29 pm Post subject: |
|
pluby wrote: | That is the same version as I have been running and I cannot reproduce this with my latest test patch. | Ok. After reinstalling the reported error is fixed. Still, I get the same error messages by the tons upon opening specific documents. I've a document where literally each and every line of it generates that same error message. I could not single out what triggers it. Just two observations:- The error messages only come up when starting NeoOffice by double clicking on the odt in the Finder (i.e. opening the file after NeoOffice is already running does not result in the same flood of error messages).
- In trying to single out sources I found that the error is reproducible by repacking content.xml, mimetype and styles.xml
Not sure if this tells you much, I will come back to the issue if I get new observations. |
|
Back to top |
|
|
pluby The Architect
Joined: Jun 16, 2003 Posts: 11949
|
Posted: Tue Feb 17, 2009 4:35 pm Post subject: |
|
Gust wrote: | Ok. After reinstalling the reported error is fixed. Still, I get the same error messages by the tons upon opening specific documents. I've a document where literally each and every line of it generates that same error message. I could not single out what triggers it. |
Can you attach a sample document that I can use to try to reproduce this behavior?
Click this link for instuctions on how to attach files to your post
Patrick |
|
Back to top |
|
|
anrun Blue Pill
Joined: Feb 18, 2009 Posts: 2
|
Posted: Wed Feb 18, 2009 1:48 am Post subject: |
|
last path helps me (languagetool - russian)
thanx |
|
Back to top |
|
|
|