Bug 200055 - [spell checking] BadLocationException thrown for newly created class
Summary: [spell checking] BadLocationException thrown for newly created class
Status: RESOLVED FIXED
Alias: None
Product: JDT
Classification: Eclipse Project
Component: Text (show other bugs)
Version: 3.3   Edit
Hardware: All All
: P3 normal (vote)
Target Milestone: 3.4 M7   Edit
Assignee: JDT-Text-Inbox CLA
QA Contact:
URL:
Whiteboard:
Keywords: needinfo
: 218590 (view as bug list)
Depends on:
Blocks:
 
Reported: 2007-08-15 11:42 EDT by Dmitry Stadnik CLA
Modified: 2011-05-10 01:52 EDT (History)
7 users (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Dmitry Stadnik CLA 2007-08-15 11:42:13 EDT
eclipse.buildId=I20070625-1500
java.version=1.5.0_07
java.vendor=Apple Computer, Inc.
BootLoader constants: OS=macosx, ARCH=x86, WS=carbon, NL=en_US
Framework arguments:  -keyring /Users/dstadnik/.eclipse_keyring -showlocation
Command-line arguments:  -os macosx -ws carbon -arch x86 -keyring /Users/dstadnik/.eclipse_keyring -consoleLog -showlocation

Error
Wed Aug 15 17:39:16 CEST 2007
Internal Error

org.eclipse.jface.text.BadLocationException
at org.eclipse.jface.text.AbstractDocument.computePartitioning(AbstractDocument.java:1296)
at org.eclipse.jface.text.TextUtilities.computePartitioning(TextUtilities.java:428)
at org.eclipse.jdt.internal.ui.text.spelling.JavaSpellingEngine.check(JavaSpellingEngine.java:55)
at org.eclipse.jdt.internal.ui.text.spelling.SpellingEngine.check(SpellingEngine.java:77)
at org.eclipse.jdt.internal.ui.text.spelling.DefaultSpellingEngine.check(DefaultSpellingEngine.java:75)
at org.eclipse.ui.texteditor.spelling.SpellingService$1.run(SpellingService.java:103)
at org.eclipse.core.runtime.SafeRunner.run(SafeRunner.java:37)
at org.eclipse.ui.texteditor.spelling.SpellingService.check(SpellingService.java:108)
at org.eclipse.ui.texteditor.spelling.SpellingService.check(SpellingService.java:80)
at org.eclipse.ui.texteditor.spelling.SpellingReconcileStrategy.reconcile(SpellingReconcileStrategy.java:176)
at org.eclipse.jdt.internal.ui.text.spelling.JavaSpellingReconcileStrategy.reconcile(JavaSpellingReconcileStrategy.java:125)
at org.eclipse.jdt.internal.ui.text.CompositeReconcilingStrategy.reconcile(CompositeReconcilingStrategy.java:86)
at org.eclipse.jdt.internal.ui.text.JavaCompositeReconcilingStrategy.reconcile(JavaCompositeReconcilingStrategy.java:96)
at org.eclipse.jface.text.reconciler.MonoReconciler.process(MonoReconciler.java:75)
at org.eclipse.jdt.internal.ui.text.JavaReconciler.process(JavaReconciler.java:378)
at org.eclipse.jface.text.reconciler.AbstractReconciler$BackgroundThread.run(AbstractReconciler.java:204)
Comment 1 Dani Megert CLA 2007-08-21 08:20:00 EDT
Works for me. Please provide more info/steps if you see this again.
Comment 2 Dani Megert CLA 2008-02-12 03:12:05 EST
*** Bug 218590 has been marked as a duplicate of this bug. ***
Comment 3 Frederic Fusier CLA 2008-03-17 13:49:12 EDT
Using build I20080305-1100, as there was a lot of difficulty to have a usable build last week...

Since yesterday, I got the following exception twice while editing a Java file:
org.eclipse.jface.text.BadLocationException
	at org.eclipse.jface.text.AbstractDocument.computePartitioning(AbstractDocument.java:1304)
	at org.eclipse.jface.text.TextUtilities.computePartitioning(TextUtilities.java:428)
	at org.eclipse.jdt.internal.ui.text.spelling.JavaSpellingEngine.check(JavaSpellingEngine.java:49)
	at org.eclipse.jdt.internal.ui.text.spelling.SpellingEngine.check(SpellingEngine.java:90)
	at org.eclipse.jdt.internal.ui.text.spelling.DefaultSpellingEngine.check(DefaultSpellingEngine.java:75)
	at org.eclipse.ui.texteditor.spelling.SpellingService$1.run(SpellingService.java:103)
	at org.eclipse.core.runtime.SafeRunner.run(SafeRunner.java:37)
	at org.eclipse.ui.texteditor.spelling.SpellingService.check(SpellingService.java:108)
	at org.eclipse.ui.texteditor.spelling.SpellingService.check(SpellingService.java:80)
	at org.eclipse.ui.texteditor.spelling.SpellingReconcileStrategy.reconcile(SpellingReconcileStrategy.java:179)
	at org.eclipse.jdt.internal.ui.text.spelling.JavaSpellingReconcileStrategy.reconcile(JavaSpellingReconcileStrategy.java:125)
	at org.eclipse.jdt.internal.ui.text.CompositeReconcilingStrategy.reconcile(CompositeReconcilingStrategy.java:86)
	at org.eclipse.jdt.internal.ui.text.JavaCompositeReconcilingStrategy.reconcile(JavaCompositeReconcilingStrategy.java:102)
	at org.eclipse.jface.text.reconciler.MonoReconciler.process(MonoReconciler.java:77)
	at org.eclipse.jface.text.reconciler.AbstractReconciler$BackgroundThread.run(AbstractReconciler.java:206)

The second time, I'm sure I was undoing a change in the editor, but I can't remember what the precise action I was doing when it happened the first time...

After this exception, the editor was entirely grey (e.g. no text was displayed) but I was able to save my last changes. However, I was no longer able to reopen the file: it always failed with  as I systematically got an AssertionFailedException (I can attach the stack trace if necessary)...

The workaround to be able to open again the file was to close and reopen my eclipse session :-(

So, as I got it twice in 2 days, I reopen this bug and increase a little bit its severity...
Comment 4 Dani Megert CLA 2008-03-18 02:54:41 EDT
I DO believe you that you see this but as said before: I can't do much if I cannot reproduce and if you cannot give more details.

Is the summary still valid? I doubt reading your last comment. I assume the file was open more than once which isn't the case when just create a new class.

If you prefer to have it open again - ok - but as said - no work on this until more steps.
Comment 5 Frederic Fusier CLA 2008-03-18 04:49:50 EDT
Usually when you set a bug to WORKSFORME, that means it happened at one time in an old version and never happens again after... This is definitely not the case here.
So, I would say keep it open until we're sure not to encounter this problem again.

As this error seems to be erratic, perhaps may you give me (us) advice to provide more information the next time it happens or some steps just after to verify some assumption(s) the origin of the problem after having a look at the stack trace...
Comment 6 Dani Megert CLA 2008-03-18 09:40:10 EDT
.
Comment 7 Markus Keller CLA 2008-04-23 09:54:41 EDT
I've had many of these with the latest plug-in export in I20080415-1646. Before, I've seen this at most once a month.

I can't reproduce, but I had a simple scenario that first produced the exception, but when I did exactly the same again, I didn't get the exception any more (I opened a CUEditor on a file whose file buffer was previously not open, pasted a line comment, inserted a space between the two slashes, pressed Arrow_Left, pressed delete).

org.eclipse.jface.text.BadLocationException
	at org.eclipse.jface.text.AbstractDocument.computePartitioning(AbstractDocument.java:1381)
	at org.eclipse.jface.text.TextUtilities.computePartitioning(TextUtilities.java:428)
	at org.eclipse.jdt.internal.ui.text.spelling.JavaSpellingEngine.check(JavaSpellingEngine.java:47)
	at org.eclipse.jdt.internal.ui.text.spelling.SpellingEngine.check(SpellingEngine.java:90)
	at org.eclipse.jdt.internal.ui.text.spelling.DefaultSpellingEngine.check(DefaultSpellingEngine.java:75)
	at org.eclipse.ui.texteditor.spelling.SpellingService$1.run(SpellingService.java:103)
	at org.eclipse.core.runtime.SafeRunner.run(SafeRunner.java:37)
	at org.eclipse.ui.texteditor.spelling.SpellingService.check(SpellingService.java:108)
	at org.eclipse.ui.texteditor.spelling.SpellingReconcileStrategy.reconcile(SpellingReconcileStrategy.java:198)
	at org.eclipse.jdt.internal.ui.text.spelling.JavaSpellingReconcileStrategy.reconcile(JavaSpellingReconcileStrategy.java:125)
	at org.eclipse.jdt.internal.ui.text.CompositeReconcilingStrategy.reconcile(CompositeReconcilingStrategy.java:86)
	at org.eclipse.jdt.internal.ui.text.JavaCompositeReconcilingStrategy.reconcile(JavaCompositeReconcilingStrategy.java:102)
	at org.eclipse.jface.text.reconciler.MonoReconciler.process(MonoReconciler.java:77)
	at org.eclipse.jface.text.reconciler.AbstractReconciler$BackgroundThread.run(AbstractReconciler.java:206)
Comment 8 Dani Megert CLA 2008-04-24 10:42:14 EDT
Fixed in HEAD.
Available in builds > N20080423-2000.
Comment 9 sangeeta CLA 2011-05-10 01:33:13 EDT
(In reply to comment #0)
> eclipse.buildId=I20070625-1500
> java.version=1.5.0_07
> java.vendor=Apple Computer, Inc.
> BootLoader constants: OS=macosx, ARCH=x86, WS=carbon, NL=en_US
> Framework arguments:  -keyring /Users/dstadnik/.eclipse_keyring -showlocation
> Command-line arguments:  -os macosx -ws carbon -arch x86 -keyring
> /Users/dstadnik/.eclipse_keyring -consoleLog -showlocation
> 
> Error
> Wed Aug 15 17:39:16 CEST 2007
> Internal Error
> 
> org.eclipse.jface.text.BadLocationException
> at
> org.eclipse.jface.text.AbstractDocument.computePartitioning(AbstractDocument.java:1296)
> at
> org.eclipse.jface.text.TextUtilities.computePartitioning(TextUtilities.java:428)
> at
> org.eclipse.jdt.internal.ui.text.spelling.JavaSpellingEngine.check(JavaSpellingEngine.java:55)
> at
> org.eclipse.jdt.internal.ui.text.spelling.SpellingEngine.check(SpellingEngine.java:77)
> at
> org.eclipse.jdt.internal.ui.text.spelling.DefaultSpellingEngine.check(DefaultSpellingEngine.java:75)
> at
> org.eclipse.ui.texteditor.spelling.SpellingService$1.run(SpellingService.java:103)
> at org.eclipse.core.runtime.SafeRunner.run(SafeRunner.java:37)
> at
> org.eclipse.ui.texteditor.spelling.SpellingService.check(SpellingService.java:108)
> at
> org.eclipse.ui.texteditor.spelling.SpellingService.check(SpellingService.java:80)
> at
> org.eclipse.ui.texteditor.spelling.SpellingReconcileStrategy.reconcile(SpellingReconcileStrategy.java:176)
> at
> org.eclipse.jdt.internal.ui.text.spelling.JavaSpellingReconcileStrategy.reconcile(JavaSpellingReconcileStrategy.java:125)
> at
> org.eclipse.jdt.internal.ui.text.CompositeReconcilingStrategy.reconcile(CompositeReconcilingStrategy.java:86)
> at
> org.eclipse.jdt.internal.ui.text.JavaCompositeReconcilingStrategy.reconcile(JavaCompositeReconcilingStrategy.java:96)
> at
> org.eclipse.jface.text.reconciler.MonoReconciler.process(MonoReconciler.java:75)
> at
> org.eclipse.jdt.internal.ui.text.JavaReconciler.process(JavaReconciler.java:378)
> at
> org.eclipse.jface.text.reconciler.AbstractReconciler$BackgroundThread.run(AbstractReconciler.java:204)
Comment 10 Dani Megert CLA 2011-05-10 01:52:25 EDT
(In reply to comment #9)
What's the idea of this comment?