64

I am using Eclipse for quite some time and I still haven't found how to configure the Problems View to display only the Errors and Warnings of interest. Is there an easy way to filter out warnings from a specific resource or from a specific path? For example, when I generate javadoc I get tons of irrelevant html warnings. Also, is there a way to change the maximum number of appearing warnings/errors?

I am aware of the filters concept, but I am looking for some real life examples. What kind of filters or practices do other people use?

Edit: I found the advice to filter on "On selected element and its children" to be the best one. I have one other issue however. If I have "a lot" of warnings or errors, only the first 100 appear. In the rare case I want to see all of them, how do I do it?

kgiannakakis
  • 103,016
  • 27
  • 158
  • 194

8 Answers8

65

I feel that filtering "On selected element and its children" is the best mode of Problems view filter, because it allows you to very quickly narrow down the scope of reported problems: click on Working Set (in Package Explorer), and it shows all problems in all projects in the set; click on a project - and only problems in the selected project appear. Click on individual class (or package) - only problems in the selected class (or package) are shown. So you don't get distracted with problems unrelated to your task at hand.

Jason S
  • 184,598
  • 164
  • 608
  • 970
Valters Vingolds
  • 1,271
  • 10
  • 16
  • 2
    Thanks Buddy that helped me too to narrow down on resolving warnings:)+1 for that And to solve using navigator will simplify the process further .Like folder wise rather than package.:):) – Ravisha Aug 09 '10 at 04:47
  • THANKS Ravisha!! I was searching a problem for 9 hours now and using this little filter thing I was able to track things down!! – Basic Coder Dec 01 '13 at 01:51
32

In the top right hand corner of the problems pane is a filter button (it looks like three arrows pointing to the right), clicking that will let you configure the view. You can filter by element, such as the class you're editing or working set, the type of problem (e.g. java problems, buildfile problems etc..) and by severity. It's actually very configurable.

See http://help.eclipse.org/help32/index.jsp?topic=/org.eclipse.platform.doc.user/concepts/cprbview.htm for details and screenshots.

vitaut
  • 49,672
  • 25
  • 199
  • 336
slashnick
  • 26,167
  • 10
  • 55
  • 67
  • 10
    Rather than three arrows, my version (Galileo; 20090920-1017) has a single downward arrow which brings up a menu. Filtering options are listed under 'Show'. – Quantum7 Jan 23 '10 at 01:32
  • 2
    Thank you SOOO much for that link! I was going nuts looking for the button but for some reason my version of Eclipse doesn't have it. I had to press the down arrow in top right hand corner of the problems pane and hit 'configure contents'. Just like in the link. Thanks again!! – AnthonyW May 17 '13 at 18:53
21

To view more than 100 warnings, go to the problem view's drop down menu (use the little arrow next to the minimize button on the view), select Preferences, and you will have the option to change this limit from 100 to another number.

This information is for Ganymede; things have changed since Europa and I'm not sure of all the differences.

skiphoppy
  • 97,646
  • 72
  • 174
  • 218
  • I went to windows - preferences - java - compiler - building and set the preferences there, but without setting the view described here it didn't work. Thank you so much for this answer! – James Drinkard Sep 21 '11 at 17:20
  • Life saver, been hitting the brick wall for ages until coming across this post, thanks. FYI, in ME Blue 10.6, the drop-down that triggers the dialog needed is under Configure Contents (not Preferences). – Alz Oct 02 '12 at 22:06
5

An updated link for Ganymede (Eclipse 3.4):

http://help.eclipse.org/ganymede/topic/org.eclipse.platform.doc.user/concepts/cprbview.htm

But I agree with the fundamental problem: the Problems view needs filtering by Resource, not just Description.

In my case, I include generated jsp code in my source path, and there are all kinds of warning that occur in the *_jsp.java files (like unused application, page, out, config, page_context variables). So it would be nice to exclude them by the Resource pattern. (Or for jspc to not write unused code...but that's a different issue altogether).

Ben
  • 4,785
  • 3
  • 27
  • 39
5

Re: your edit

In the drop down button by the filter button, there is a preferences option. Uncheck "Use Marker Limits" and you will be shown all errors + warnings.

ashirley
  • 1,148
  • 1
  • 12
  • 19
2

In order to view more than 100 warnings, go to the problem view's drop down menu (use the little arrow next to the minimize button on the view), select Configure Contents. Uncheck the Use item limitsat the bottom left of the Configure Contents window or set a limit in the Number of items visible per group:.

mliebelt
  • 15,345
  • 7
  • 55
  • 92
Claude COULOMBE
  • 3,434
  • 2
  • 36
  • 39
1

Open problems view. Click corner triangle. Select preferences

Uncross: [ ] Use marker limits

Joonas
  • 66
  • 2
0

Make sure you don't forget to uncheck "Show all items" on top left corner of Filters window. I was applying all these filters such as 'On selected elements and its children' but it doesn't seem to work out. Finally I unchecked the aforementioned checkbox, selected the required 'Configurations' and then it started working.

Bhuvanesh Mani
  • 1,394
  • 14
  • 23