A strange error is being generated

Originally asked by Roman on 10 April 2020 (original question)


While performing a synchronization on Jira Cloud an error is generated saying

Field customfield_10459: Option id 'null' is not valid.

What does this mean an how can this be fixed?


Answer by Juan Grases on 10 April 2020

This error indicates that a invalid value is being assigned to the custom field with id 10459. This usually happen when mapping the custom field of type lists as they come from the remote side doing something like:

issue.customFields."Cf Name".value = replica.customFields."Cf Name".value.value

or similar. The steps I recommend to deal with this are:

  • Identify which CF has such ID
  • Check what value are you setting on it (on the bottom of the error details page, you can access the incoming message where you can see the value received from the remote side)
  • Map that value to a proper valid value on your system.
def remoteValue = replica.customFields."Cf Name".value.value

def listMap = ["High": "Critical"]

issue.customFields."Cf Name".value  = listMap[remoteValue] ?: remoteValue

This topic was automatically closed 2 days after the last reply. New replies are no longer allowed.