java.lang.NumberFormatException: For input string: Error in Issue Navigator when Sorting by Calculated Field
Symptoms
When a sort is attempted in a calculated field (such as provided by the JIRA Misc Custom Fields Plugin), the Issue Navigator throws a stack trace.
The following appears in the atlassian-jira.log
:
Arithemetic Exception in binary op
Diagnosis
To ensure this describes the error you're seeing, attempt to create a test project with a small number of issues, and ensure that for each issue the calculated field resolves to a valid value. Once that is confirmed, try the following JQL:
project = "Test Project" ORDER BY <customfieldid> ASC
If the search returns an Issue Navigator, then you have confirmed this bug.
Cause
This is caused by invalid values being inserted into the search index by the plugin.
Workaround
Workarounds include:
- Remove offending plugin
- Edit all affected issues to ensure that all calculations result in valid numeric values
- Delete any non-conforming issues
Resolution
At this time, there is no resolution for this issue. JMCF-45 describes it in the JIRA Misc Custom Fields plugin. If you are running across this issue in association with that plugin, please Vote for that issue to increase its visibility to Development, or Watch this issue to remain appraised as it progresses through the development process.