| Summary: | Error Log view does not display child entries for new exceptions | ||
|---|---|---|---|
| Product: | [Eclipse Project] PDE | Reporter: | Dani Megert <daniel_megert> |
| Component: | UI | Assignee: | Dani Megert <daniel_megert> |
| Status: | RESOLVED FIXED | QA Contact: | |
| Severity: | normal | ||
| Priority: | P3 | CC: | curtis.windatt.public, daniel_megert, stepper |
| Version: | 4.3 | ||
| Target Milestone: | 4.4 M2 | ||
| Hardware: | All | ||
| OS: | All | ||
| Whiteboard: | |||
The first time (step 6) works because it's the first log entry and there, the view just reads in the .log file. Afterwards entries are created when a log event occurs. Creating an entry (LogView.createLogEntry(IStatus)) does not honor mutli-status and sub-entries. Fixed with http://git.eclipse.org/c/pde/eclipse.pde.ui.git/commit/?id=0732c3f2ee04fe49960e699bac35acd674a4f9c0 This fix was not good because it duplicates the children of MultiStatus entries. This code that you've added to LogView.createLogEntry(IStatus) adds new child entries:
private LogEntry createLogEntry(IStatus status) {
LogEntry entry = new LogEntry(status);
// [...]
if (status.isMultiStatus()) {
IStatus[] children = status.getChildren();
for (int i = 0; i < children.length; i++) {
LogEntry childEntry = createLogEntry(children[i]);
entry.addChild(childEntry);
childEntry.setSession(currentSession);
}
}
But child entries for the child statuses have already been added in new LogEntry(status). I've submitted a Gerrit review that also fixes the problem that the implicitely created child entries have no session set:
https://git.eclipse.org/r/#/c/22151/
(In reply to Eike Stepper from comment #3) > This fix was not good because it duplicates the children of MultiStatus > entries. Can you please provide a test case that surfaces the problem in the UI? Does your fix still fix the original issue from comment 0? This bug here was fixed in M2. If it surfaces a new problem then please file a new bug report with steps that show the issue in the UI. (In reply to Dani Megert from comment #5) > This bug here was fixed in M2. If it surfaces a new problem then please file > a new bug report with steps that show the issue in the UI. Done. See bug 429372. (In reply to Dani Megert from comment #4) > Does your fix still fix the original issue from comment 0? Gerrit runs the respective test case and succeeds, right? |
At least broken since 3.7. Error Log view does not display child entries for new exceptions. Test Case: 1. paste the following snippet into the 'Package Explorer': /* wörst */ public class Bug {} 2. close the editor 3. change the project's encoding to 'US-ASCII' 4. open the 'Error Log' view 5. select the project in the 'Package Explorer' 6. Source > Format ==> OK: an entry with children appears in the 'Error Log' view 7. Source > Format ==> BUG: an entry without children appears in the 'Error Log' view