Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.
Bug 365728 - Maven JDT compiler produces incoherent error output
Summary: Maven JDT compiler produces incoherent error output
Status: RESOLVED FIXED
Alias: None
Product: z_Archived
Classification: Eclipse Foundation
Component: Tycho (show other bugs)
Version: unspecified   Edit
Hardware: All All
: P3 minor (vote)
Target Milestone: ---   Edit
Assignee: Jan Sievers CLA
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2011-12-06 08:46 EST by Missing name CLA
Modified: 2021-04-28 16:55 EDT (History)
1 user (show)

See Also:


Attachments
Patch that proposes a better compiler error/warning stream parsing (26.50 KB, patch)
2011-12-06 08:51 EST, Missing name CLA
jan.sievers: iplog+
Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Missing name CLA 2011-12-06 08:46:41 EST
Build Identifier: 

When the Maven JDT Compiler parses the stream given by the compiler itself, it tries to add some additional information that cannot be correct:
- Column number of the error is not parsable as whitespaces are incorrectly rendered. Column number should be set to '0'
- Underlining of the error is badly placed for the same reason (and also makes the output rather difficult to read). It should not be printed 

Reproducible: Always
Comment 1 Missing name CLA 2011-12-06 08:51:29 EST
Created attachment 207985 [details]
Patch that proposes a better compiler error/warning stream parsing
Comment 2 Jan Sievers CLA 2011-12-09 08:51:47 EST
thanks for the patch, I intend to merge it.

We just need to follow some rules described in [1].

You need to answer the following questions:

1.  Did you author 100% of the content you are contributing
2.  Do you have the rights to donate the content to Eclipse
3.  Are you contributing the content under the EPL

As a side note for future patches, we prefer the patch format provided by git format-patch because it preserves author information and the commit message. I just created a wiki page for this [2]

[1] http://wiki.eclipse.org/Development_Resources/Handling_Git_Contributions
[2] http://wiki.eclipse.org/Tycho/Contributor_Guide
Comment 3 Missing name CLA 2011-12-12 07:09:00 EST
Here are my answers:

1.  Did you author 100% of the content you are contributing
Yes
2.  Do you have the rights to donate the content to Eclipse
Yes
3.  Are you contributing the content under the EPL
Yes

I'll try to use the correct format next time ;)
Comment 4 Jan Sievers CLA 2011-12-12 17:45:18 EST
http://git.eclipse.org/c/tycho/org.eclipse.tycho.git/commit/?id=7f0a5f5a1de1a722bfe0f3f0c2f25608ead5e075

I kept the additional context lines as they still provide helpful information IMHO (given that the user only gets it when he explicily asked for it with showWarnings=true)

Duplicated output as well as line number info is fixed, column is now always 0.
Added unit tests.

I assume we can resolve this bug now.