Share

FindBugs

Tracker: Bugs

5 Ant task fails with IllegalArgumentException - ID: 2820089
Last Update: Comment added ( sf-robot )

When I try to run the Ant task, I get:

[findbugs] Running FindBugs...
[findbugs] java.lang.IllegalArgumentException: Unknown option:
-sortByClass
[findbugs] at
edu.umd.cs.findbugs.config.CommandLine.parse(CommandLine.java:259)
[findbugs] at
edu.umd.cs.findbugs.config.CommandLine.parse(CommandLine.java:206)
[findbugs] at edu.umd.cs.findbugs.gui2.Driver.main(Driver.java:54)
[findbugs] at sun.reflect.NativeMethodAccessorImpl.invoke0(Native
Method)
[findbugs] at
sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:3
9)
[findbugs] at
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImp
l.java:25)
[findbugs] at java.lang.reflect.Method.invoke(Method.java:597)
[findbugs] at
edu.umd.cs.findbugs.LaunchAppropriateUI.launch(LaunchAppropriateUI.java:127
)
[findbugs] at
edu.umd.cs.findbugs.LaunchAppropriateUI.main(LaunchAppropriateUI.java:203)
[findbugs] edu.umd.cs.findbugs.gui2.Driver [options] [project or analysis
results file]

My build.xml invokes FindBugs with:

<findbugs home="${findbugs.home}" output="html"
outputFile="findbugs_unit_tests/findbugs_output.html" jvmargs="-Xmx1024m"
reportLevel="high" failonerror="true">

It looks like FindBugs is trying to start the GUI rather than the command
line interface, which seems a bit weird.

System details:
Windows xp
Sun Java 1.6.0_06
Ant 1.7.0
FindBugs 1.3.7


Hedley Proctor ( hedleyproctor ) - 2009-07-11 15:40

5

Closed

Works For Me

William Pugh

Ant task

None

Public


Comments ( 3 )

Date: 2009-08-15 02:20
Sender: sf-robotSourceForge.net Site Admin

This Tracker item was closed automatically by the system. It was
previously set to a Pending status, and the original submitter
did not respond within 14 days (the time period specified by
the administrator of this Tracker).


Date: 2009-07-31 15:26
Sender: wpughSourceForge.net SubscriberProject Admin

I can't reproduce this with FindBugs 1.3.7 or later versions.

Can you provide an entire build.xml file showing the problem. In
particular, can you provide the taskdef you use?
It should be something like:

<taskdef name="findbugs"
classname="edu.umd.cs.findbugs.anttask.FindBugsTask"
classpath="${anttask.jar}"/>


You might also try it with version 1.3.8.


Date: 2009-07-13 05:12
Sender: andyandyAccepting Donations

Please try to reproduce this with the latest released version (1.3.8).

Regards,
Andrei


Attached File

No Files Currently Attached

Changes ( 7 )

Field Old Value Date By
status_id Pending 2009-08-15 02:20 sf-robot
allow_comments 1 2009-08-15 02:20 sf-robot
close_date 2009-07-31 15:26 2009-08-15 02:20 sf-robot
status_id Open 2009-07-31 15:26 wpugh
close_date - 2009-07-31 15:26 wpugh
resolution_id None 2009-07-31 15:26 wpugh
assigned_to nobody 2009-07-31 15:26 wpugh