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 248769 - New tab open
Summary: New tab open
Status: NEW
Alias: None
Product: debugger
Classification: Unclassified
Component: Java (show other bugs)
Version: 8.0.2
Hardware: PC Linux
: P3 normal (vote)
Assignee: Martin Entlicher
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2014-11-20 08:10 UTC by infolab
Modified: 2016-09-12 13:23 UTC (History)
0 users

See Also:
Issue Type: DEFECT
Exception Reporter:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description infolab 2014-11-20 08:10:14 UTC
In a debug session, when entering in a class, a new tab is opened even if a tab already exist for this class. Then bookmarks and breakpoints are not well reflected in the two tabs and unuseful tabs are multiplied.
Comment 1 infolab 2016-09-07 15:14:19 UTC
This bug is always on 8.1
Comment 2 Martin Entlicher 2016-09-12 09:50:34 UTC
Can you please provide steps to reproduce?
It looks like a configuration issue. A sample project would help.
Comment 3 infolab 2016-09-12 10:38:55 UTC
(In reply to Martin Entlicher from comment #2)
> Can you please provide steps to reproduce?
> It looks like a configuration issue. A sample project would help.

1) Open a project.
2) Open a class.
3) Put a breakpoint in this class.
4) Start debug session.

When you reach the breakpoint, the class is opened again.
Comment 4 Martin Entlicher 2016-09-12 11:33:01 UTC
> 1) Open a project.

Which project? This is why I asked for a sample project.
It can not be reproduced with every project.
Create new project Samples -> Java -> Anagrame Game for instance, put breakpoint to Anagrams.java:89 for instance and after debug of the project, the already opened Anagrams.java is shown with the green line.
Comment 5 infolab 2016-09-12 11:35:30 UTC
You can open any project. It's not a project bug, it's a netbeans bug. Are you using eclipse for working ?
Comment 6 Martin Entlicher 2016-09-12 11:44:24 UTC
I described a sequence of steps that work for me in NetBeans. In all my test projects the source files are opened just once and also in NetBeans source projects from hg.netbeans.org.
To locate the bug it's necessary that you point me to some project that exhibits this behavior during debugging.
Comment 7 Martin Entlicher 2016-09-12 11:45:34 UTC
And BTW I'm using NetBeans exclusively for development and testing.
Comment 8 infolab 2016-09-12 12:04:13 UTC
(In reply to Martin Entlicher from comment #6)
> I described a sequence of steps that work for me in NetBeans. In all my test
> projects the source files are opened just once and also in NetBeans source
> projects from hg.netbeans.org.
> To locate the bug it's necessary that you point me to some project that
> exhibits this behavior during debugging.

I have this problem with all project. Is there an exotic option which control this behavior ?
Comment 9 infolab 2016-09-12 12:14:44 UTC
In the Netbeans options (Java tab/java debugger) this option is checked :
Reuse Editor when displaying source code.
Help say -> Displays the source file containing the called method in an existing editor window instead of opening a new editor window. But this is not the behavior that I have.
Comment 10 Martin Entlicher 2016-09-12 12:20:44 UTC
That option is for replacing files in tabs opened during debugging. It's something a bit different. When Class1 is opened by debugger and you step into Class2 then, the tab with Class1 is replaces with Class2. But there is broken something more fundamental in your case.

There might be something corrupted in the NetBeans settings which are saved in NetBeans' user dir.
Can you please run NetBeans with
--userdir /tmp/NBTest
option, answer no to the settings import and try to debug the project there? Will it behave O.K.?
Comment 11 infolab 2016-09-12 13:23:55 UTC
(In reply to Martin Entlicher from comment #10)
> That option is for replacing files in tabs opened during debugging. It's
> something a bit different. When Class1 is opened by debugger and you step
> into Class2 then, the tab with Class1 is replaces with Class2. But there is
> broken something more fundamental in your case.
> 
> There might be something corrupted in the NetBeans settings which are saved
> in NetBeans' user dir.
> Can you please run NetBeans with
> --userdir /tmp/NBTest
> option, answer no to the settings import and try to debug the project there?
> Will it behave O.K.?

No change. But I have found why problem happen or not. It happen only with class of project other than main project (a library project).