Bug 565406 - Unable to install breakpoint warning
Summary: Unable to install breakpoint warning
Status: NEW
Alias: None
Product: JDT
Classification: Eclipse Project
Component: Debug (show other bugs)
Version: 4.14   Edit
Hardware: PC Linux
: P3 normal (vote)
Target Milestone: ---   Edit
Assignee: JDT-Debug-Inbox CLA
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2020-07-21 12:50 EDT by Lars Vogel CLA
Modified: 2022-07-05 11:37 EDT (History)
3 users (show)

See Also:


Attachments
Screenshot (22.41 KB, image/png)
2020-07-21 12:50 EDT, Lars Vogel CLA
no flags Details
Me reproducing the error (396.60 KB, image/gif)
2022-06-26 20:04 EDT, Omar Sweidan CLA
no flags Details

Note You need to log in before you can comment on or make changes to this bug.
Description Lars Vogel CLA 2020-07-21 12:50:07 EDT
Created attachment 283666 [details]
Screenshot

During debugging the following method I got the warning from the screenshot.


public List<Beer> getBeerNamesFromProperty(List<String> beerNames) {
			return beerNames.stream().map(bN -> (Beer) () -> bN).collect(Collectors.toList());
		}

Beer is defined as:

public interface Beer {
	String getName();
}
Comment 1 Sarika Sinha CLA 2020-07-22 00:43:34 EDT
Please verify that Preferences->Java->Compiler->Add line number attributes to generated class files is enabled.

Debugger uses this information to create a breakpoint.
Comment 2 Ed Willink CLA 2021-06-17 05:30:38 EDT
After upgrading from 2021-03 to 2021-06 I get six copies of the warning each time I start the debugger.

"Preferences->Java->Compiler->Add line number attributes to generated class files" is now enabled. I have no idea what the setting was prior to upgrade. However on a different nt yet upgarded machine the setting is enabled suggesting that whenever the option was introduced it was successfully set true.

Similar to the oroginal screenshot, which doesn't support cut and paste, the generated file appears to be 'doubly' generated username$$FastClassByJuice$$hexinteger. Preumably there are no sensible line numbers that can be used. unless there is a 'template' file that can be stepped. But srely no user selection of such an invosible breakpoint could ever have occurred?

Bug 1. This should not appear at all.

Bug 2. It should appear just once per debugger start up.

Bug 3. The disabled breakpoint should appear greyed-out/highlighted to ease manual deletion / source visit.

Bug 4. The impossible breakpoint popups should not appear in a subsequent debugger session since the first session should have deleted them.

Bug 5. The popup dialog shout support copy to aid bug reporting.
Comment 3 Sarika Sinha CLA 2021-06-17 05:44:06 EDT
(In reply to Ed Willink from comment #2)
> After upgrading from 2021-03 to 2021-06 I get six copies of the warning each
> time I start the debugger.
> 
> "Preferences->Java->Compiler->Add line number attributes to generated class
> files" is now enabled. I have no idea what the setting was prior to upgrade.
> However on a different nt yet upgarded machine the setting is enabled
> suggesting that whenever the option was introduced it was successfully set
> true.
> 
> Similar to the oroginal screenshot, which doesn't support cut and paste, the
> generated file appears to be 'doubly' generated
> username$$FastClassByJuice$$hexinteger. Preumably there are no sensible line
> numbers that can be used. unless there is a 'template' file that can be
> stepped. But srely no user selection of such an invosible breakpoint could
> ever have occurred?
> 
> Bug 1. This should not appear at all.
> 
> Bug 2. It should appear just once per debugger start up.
> 
> Bug 3. The disabled breakpoint should appear greyed-out/highlighted to ease
> manual deletion / source visit.
> 
> Bug 4. The impossible breakpoint popups should not appear in a subsequent
> debugger session since the first session should have deleted them.
> 
> Bug 5. The popup dialog shout support copy to aid bug reporting.

Can you attach a sample workspace from 2021-03 where I can reproduce by migrating?
Comment 4 Ed Willink CLA 2021-06-17 08:56:05 EDT
(In reply to Sarika Sinha from comment #3)
> Can you attach a sample workspace from 2021-03 where I can reproduce by
> migrating?

How much of the workspace do you want?

Attempting to ZIP my current workspace failed because (Ouch!) E:\Development\Chital\Workspace\.metadata\.plugins\org.eclipse.pde.core\.bundle_pool is 5.9GB.

My current already migrated workspace keeps showing the warning, so you could migrate back and forward or just debug what now constitutes no line numbers.

Or I could provide a not yet migrated workspace from another machine that will probably demonstrate the saem issue.
Comment 5 Sarika Sinha CLA 2021-06-17 09:02:55 EDT
(In reply to Ed Willink from comment #4)

> 
> Or I could provide a not yet migrated workspace from another machine that
> will probably demonstrate the saem issue.

This will work.
Comment 6 Omar Sweidan CLA 2022-06-26 20:02:00 EDT
Hello, people!

I use Win10 64 bit, with the latest Eclipse 4.24, but I still experience the same error message if I want to insert a breakpoint in a .class file that I opened with JDCore. The weird thing is that after I get the message, the breakpoint is being added, but I also get two messages in the Error log (see attached gif).
Comment 7 Omar Sweidan CLA 2022-06-26 20:04:35 EDT
Created attachment 288604 [details]
Me reproducing the error
Comment 8 Sarika Sinha CLA 2022-07-05 10:55:49 EDT
(In reply to Omar Sweidan from comment #7)
> Created attachment 288604 [details]
> Me reproducing the error

Adding of breakpoint or debugging can not happen if Line information is missing from .class file.
Refer to Comment #1
Comment 9 Omar Sweidan CLA 2022-07-05 11:37:45 EDT
(In reply to Sarika Sinha from comment #8)
> (In reply to Omar Sweidan from comment #7)
> > Created attachment 288604 [details]
> > Me reproducing the error
> 
> Adding of breakpoint or debugging can not happen if Line information is
> missing from .class file.
> Refer to Comment #1

Yes, I know, but in my case it is switched on in the Preferences >> Java >> Compiler section.