Inital Scan of Perforce Repository Fails with A NumberFormatException

Still need help?

The Atlassian Community is here for you.

Ask the community


An error occurs for the same revision even if the scan is restarted:

2008-07-24 10:21:14,826 DEBUG [pool-2-thread-1] P4Process-finish - Exception processing command c:\program files\perforce\p4.exe -p <host>:1666 -u <username> -ztag changes -l //depot/...@10,210
java.lang.NumberFormatException: For input string: "comment blah comment more comment"
	at java.lang.NumberFormatException.forInputString(
	at java.lang.Long.parseLong(
	at java.lang.Long.parseLong(
	at com.cenqua.fisheye.perforce.client.P4Client$3.processGroup(
	at com.cenqua.fisheye.perforce.client.P4Exec$6.processLine(
	at com.cenqua.fisheye.perforce.client.P4OutputLineProcessor.processOutput(
	at com.cenqua.fisheye.perforce.client.P4Exec$4.processOutput(


Diagnostic Steps

  1. Run the following command outside of Fisheye:

    c:\program files\perforce\p4.exe -p <host>:1666 -u <username> -ztag changes -l //depot/...@10,210

    An output similar to below will be produced:

     	... change 100
     	... time 1124169874
     	... user parthak
     	... client ATLASSIAN
     	... status submitted
     	... desc Some description ba, bla, blah
     	... change comment
     	blah comment more comment
  2. Run the same command without the -ztagparameter:

    c:\program files\perforce\p4.exe -p <host>:1666 -u <username> changes -l //depot/...@10,210

    The command above will produce the following output:

     	Change 100 on 2005/08/15 by parthak@ATLASSIAN
     	Some description ba, bla, blah
     	... change comment
     	blah comment more comment

Notice the comment has the following "... change" String.


Fisheye sends the -ztag parameter to perforce and processes the output. The "... change" string is usually followed by a revision number, but in the case above it is included in the comment and followed by some comments. When Fisheye tries to process the result, it throws a NumberFormatException because it was actually given a string while expecting for a numerical result.


Modify the comment to remove the "... change" string or modify it to prevent it from being processed.

For the case above, run the command below and modify the comment:

c:\program files\perforce\p4.exe -p <host>:1666 -u <username> change -f 100

Last modified on Jul 31, 2018

Was this helpful?

Provide feedback about this article
Powered by Confluence and Scroll Viewport.