java.lang.NumberFormatException: For input string: "sprint 1"

Atlassian JIRA | Janet Albion [Atlassian] | 4 years ago
  1. 0

    Steps to reproduce: # Install GreenHopper 6 into JIRA 5.1.1 # add Sprint field to the Create/Edit screen # create sprint in the GreenHopper/Agile(eg: Sprint 1) # create new issue in JIRA while inserting "Sprint 1" to the field Sprint or edit existing issue and insert "Sprint 1" into the Sprint field. Value will not be added, JIRA does not throws error message in the UI but, will throws error in the log: {noformat} 2012-08-17 18:24:58,287 http-8483-5 ERROR [500ErrorPage.jsp] Exception caught in 500 page For input string: "sprint 1" java.lang.NumberFormatException: For input string: "sprint 1" at java.lang.NumberFormatException.forInputString(NumberFormatException.java:48) at java.lang.Long.parseLong(Long.java:410) at java.lang.Long.valueOf(Long.java:525) at com.atlassian.greenhopper.customfield.sprint.SprintCFType.getSingularObjectFromString(SprintCFType.java:78) at com.atlassian.greenhopper.customfield.sprint.SprintCFType.getValueFromCustomFieldParams(SprintCFType.java:153) at com.atlassian.greenhopper.customfield.sprint.SprintCFType.getValueFromCustomFieldParams(SprintCFType.java:37) at com.atlassian.jira.issue.fields.CustomFieldImpl.updateIssue(CustomFieldImpl.java:1123) {noformat} # for the same issue TEST-1, insert non-existing Sprint number(eg:5). JIRA throws error message in the UI as shown in the screenshot SprintError.png . In the logs, error message: {noformat} 2012-08-17 18:07:29,168 http-8483-2 ERROR admin 1087x305x1 wsqoqb 127.0.0.1 /secure/QuickEditIssue.jspa [jira.bc.issue.DefaultIssueService] Exception occurred editing issue: java.lang.NullPointerException java.lang.NullPointerException at com.atlassian.greenhopper.customfield.sprint.SprintCFType.convertTypeToDbValue(SprintCFType.java:244) at com.atlassian.greenhopper.customfield.sprint.SprintCFType.convertTypeToDbValue(SprintCFType.java:37) {noformat} # try to create a new issue and try to insert invalid Sprint number(eg:3). Error message thrown in the JIRA UI as per Sprint-CreateIssue.png JIRA should handle the invalid value gracefully instead of throwing NullPointerException error or not responding.

    Atlassian JIRA | 4 years ago | Janet Albion [Atlassian]
    java.lang.NumberFormatException: For input string: "sprint 1"
  2. 0

    Steps to reproduce: # Install GreenHopper 6 into JIRA 5.1.1 # add Sprint field to the Create/Edit screen # create sprint in the GreenHopper/Agile(eg: Sprint 1) # create new issue in JIRA while inserting "Sprint 1" to the field Sprint or edit existing issue and insert "Sprint 1" into the Sprint field. Value will not be added, JIRA does not throws error message in the UI but, will throws error in the log: {noformat} 2012-08-17 18:24:58,287 http-8483-5 ERROR [500ErrorPage.jsp] Exception caught in 500 page For input string: "sprint 1" java.lang.NumberFormatException: For input string: "sprint 1" at java.lang.NumberFormatException.forInputString(NumberFormatException.java:48) at java.lang.Long.parseLong(Long.java:410) at java.lang.Long.valueOf(Long.java:525) at com.atlassian.greenhopper.customfield.sprint.SprintCFType.getSingularObjectFromString(SprintCFType.java:78) at com.atlassian.greenhopper.customfield.sprint.SprintCFType.getValueFromCustomFieldParams(SprintCFType.java:153) at com.atlassian.greenhopper.customfield.sprint.SprintCFType.getValueFromCustomFieldParams(SprintCFType.java:37) at com.atlassian.jira.issue.fields.CustomFieldImpl.updateIssue(CustomFieldImpl.java:1123) {noformat} # for the same issue TEST-1, insert non-existing Sprint number(eg:5). JIRA throws error message in the UI as shown in the screenshot SprintError.png . In the logs, error message: {noformat} 2012-08-17 18:07:29,168 http-8483-2 ERROR admin 1087x305x1 wsqoqb 127.0.0.1 /secure/QuickEditIssue.jspa [jira.bc.issue.DefaultIssueService] Exception occurred editing issue: java.lang.NullPointerException java.lang.NullPointerException at com.atlassian.greenhopper.customfield.sprint.SprintCFType.convertTypeToDbValue(SprintCFType.java:244) at com.atlassian.greenhopper.customfield.sprint.SprintCFType.convertTypeToDbValue(SprintCFType.java:37) {noformat} # try to create a new issue and try to insert invalid Sprint number(eg:3). Error message thrown in the JIRA UI as per Sprint-CreateIssue.png JIRA should handle the invalid value gracefully instead of throwing NullPointerException error or not responding.

    Atlassian JIRA | 4 years ago | Janet Albion [Atlassian]
    java.lang.NumberFormatException: For input string: "sprint 1"
  3. 0

    Error: Splitting failed. (on id number of node)

    GitHub | 4 years ago | arthurlutz
    java.lang.NumberFormatException: For input string: "'-1160'"
  4. Speed up your debug routine!

    Automated exception search integrated into your IDE

  5. 0

    Catch parameter parsing exception in Spring 3.0 WebMVC

    Stack Overflow | 6 years ago | Jan
    java.lang.NumberFormatException: For input string: "dojo"
  6. 0

    Apache Karaf 2.3.1 Guides

    maven.org | 11 months ago
    org.apache.felix.gogo.commands.CommandException: Unable to convert argument ids with value '[xxx]' to type java.util.List<java.lang.Long>

  1. marcbouvierdav 2 times, last 3 months ago
  2. kuldeep 4 times, last 3 months ago
  3. Piz 2 times, last 4 months ago
  4. mortalman7 4 times, last 4 months ago
  5. bpbhat77 681 times, last 8 months ago
14 unregistered visitors
Not finding the right solution?
Take a tour to get the most out of Samebug.

Tired of useless tips?

Automated exception search integrated into your IDE

Root Cause Analysis

  1. java.lang.NumberFormatException

    For input string: "sprint 1"

    at java.lang.NumberFormatException.forInputString()
  2. Java RT
    Long.valueOf
    1. java.lang.NumberFormatException.forInputString(NumberFormatException.java:48)
    2. java.lang.Long.parseLong(Long.java:410)
    3. java.lang.Long.valueOf(Long.java:525)
    3 frames
  3. com.atlassian.greenhopper
    SprintCFType.getValueFromCustomFieldParams
    1. com.atlassian.greenhopper.customfield.sprint.SprintCFType.getSingularObjectFromString(SprintCFType.java:78)
    2. com.atlassian.greenhopper.customfield.sprint.SprintCFType.getValueFromCustomFieldParams(SprintCFType.java:153)
    3. com.atlassian.greenhopper.customfield.sprint.SprintCFType.getValueFromCustomFieldParams(SprintCFType.java:37)
    3 frames
  4. com.atlassian.jira
    CustomFieldImpl.updateIssue
    1. com.atlassian.jira.issue.fields.CustomFieldImpl.updateIssue(CustomFieldImpl.java:1123)
    1 frame