This Bugzilla instance is a read-only archive of historic NetBeans bug reports. To report a bug in NetBeans please follow the project's instructions for reporting issues.

Bug 252139 - AssertionError: startPosition=0 > endPosition=0
Summary: AssertionError: startPosition=0 > endPosition=0
Status: RESOLVED FIXED
Alias: None
Product: java
Classification: Unclassified
Component: Source (show other bugs)
Version: 8.1
Hardware: All All
: P3 normal (vote)
Assignee: Svata Dedic
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2015-04-28 12:15 UTC by petrk
Modified: 2015-07-29 01:30 UTC (History)
0 users

See Also:
Issue Type: DEFECT
Exception Reporter: 216999


Attachments
stacktrace (4.52 KB, text/plain)
2015-04-28 12:15 UTC, petrk
Details

Note You need to log in before you can comment on or make changes to this bug.
Description petrk 2015-04-28 12:15:44 UTC
This bug was originally marked as duplicate of bug 195749, that is already resolved. This bug is still valid, so this seems to be another bug, but it might be related.

Build: NetBeans IDE Dev (Build 20150401-4f75e1e1e700)
VM: Java HotSpot(TM) 64-Bit Server VM, 24.51-b03, Java(TM) SE Runtime Environment, 1.7.0_51-b13
OS: Linux

User Comments:
petrk: File which was opened in IDE was recreated outside

GUEST: Inserting a reference to EJB via the insert code menu




Stacktrace: 
java.lang.AssertionError: startPosition=0 > endPosition=0
   at org.netbeans.lib.editor.util.swing.PositionRegion.assertPositionsValid(PositionRegion.java:274)
   at org.netbeans.lib.editor.util.swing.PositionRegion.<init>(PositionRegion.java:137)
   at org.netbeans.lib.editor.util.swing.PositionRegion.<init>(PositionRegion.java:147)
   at org.netbeans.modules.java.source.parsing.DocPositionRegion.<init>(DocPositionRegion.java:61)
   at org.netbeans.modules.java.source.parsing.FindMethodRegionsVisitor.visitMethod(FindMethodRegionsVisitor.java:112)
   at org.netbeans.modules.java.source.parsing.FindMethodRegionsVisitor.visitMethod(FindMethodRegionsVisitor.java:62)
Comment 1 petrk 2015-04-28 12:15:46 UTC
Created attachment 153432 [details]
stacktrace
Comment 2 Svata Dedic 2015-07-23 14:35:20 UTC
The assert fails if start > end (greater, not greater-and-equal), so the reported text leads me to believe that there's some race condition.
Comment 3 Svata Dedic 2015-07-24 07:53:37 UTC
Fixed as jet-main#0dfcef5b74f7
Comment 4 Quality Engineering 2015-07-29 01:30:48 UTC
Integrated into 'main-silver', will be available in build *201507290002* on http://bits.netbeans.org/dev/nightly/ (upload may still be in progress)

Changeset: http://hg.netbeans.org/main-silver/rev/0dfcef5b74f7
User: Svata Dedic <sdedic@netbeans.org>
Log: #252139: Method regions collected under document read-lock