JIRA Incoming Email Handler Cannot be Created

Platform Notice: Data Center Only - This article only applies to Atlassian products on the Data Center platform.

Note that this KB was created for the Data Center version of the product. Data Center KBs for non-Data-Center-specific features may also work for Server versions of the product, however they have not been tested. Support for Server* products ended on February 15th 2024. If you are running a Server product, you can visit the Atlassian Server end of support announcement to review your migration options.

*Except Fisheye and Crucible

Summary

Problem

When attempting to create an incoming mail handler, after selecting the mail server and specifying which folder JIRA should create issue from as well as the option on how to handler emails (Create new issues always, create new issue and update existing, e.t.c) when the user presses Next, they would have the continuous spinning icon without the expected pop-up to configure which project, issue type, e.t.c that the email handler is for.

The following appears in the browser Console error

1 2 3 4 5 6 7 8 9 10 11 Uncaught TypeError: Cannot read property 'get' of undefined at child.setSelectedId (batch.js?healthcheck-resources=true&is-server-instance=true&is-system-admin=true&locale=en-US&nps-a…:1435) at child.changeSelected (batch.js?healthcheck-resources=true&is-server-instance=true&is-system-admin=true&locale=en-US&nps-a…:1488) at HTMLSelectElement.dispatch (batch.js?locale=en-US:5012) at HTMLSelectElement.eventHandle (batch.js?locale=en-US:4621) at Object.trigger (batch.js?locale=en-US:4890) at HTMLSelectElement.<anonymous> (batch.js?locale=en-US:5549) at Function.each (batch.js?locale=en-US:2340) at init.each (batch.js?locale=en-US:1951) at init.trigger (batch.js?locale=en-US:5548) at child.setSelectedId (batch.js?healthcheck-resources=true&is-server-instance=true&is-system-admin=true&locale=en-US&nps-a…:1503)

When you click on the batch.js script link, it would redirect you to the following:

1 2 3 4 5 6 7 8 9 10 ;;/* module-key = 'com.atlassian.jira.jira-mail-plugin:edit-handler-details-page', location = 'javascript/views/issue-types-view.js' */ define('jira/mail/views/issue-types-view', ['jira/mail/views/options-view', 'jquery'], function(OptionsView, jQuery) { return OptionsView.extend({ setSelectedId: function(issueTypeId) { var selectedType = this.collection.find(function(type) { return type.get("id") == issueTypeId; }); this.model.set({ "issueTypeId": selectedType.get("id") });

Diagnosis

Diagnostic Steps

  • Query your JIRA instance database to ensure that the default issue type scheme has values in it:

    1 select * from optionconfiguration where fieldconfig = '10000';

Cause

The problem is caused when your JIRA instance does not have any values associated with the default issue type scheme.

Solution

Workaround

  1. Shutdown JIRA

    Always back up your data before making any database modifications. If possible, test any alter, insert, update, or delete SQL commands on a staging server first.

  2. Re-associate back the issue types to default issue type scheme:

    1 2 3 4 5 insert into optionconfiguration (id,fieldid,optionid,fieldconfig,sequence) values ('10306','issuetype','10000','10000','0'); insert into optionconfiguration (id,fieldid,optionid,fieldconfig,sequence) values ('10307','issuetype','10001','10000','1'); insert into optionconfiguration (id,fieldid,optionid,fieldconfig,sequence) values ('10308','issuetype','10002','10000','2'); insert into optionconfiguration (id,fieldid,optionid,fieldconfig,sequence) values ('10304','issuetype','10003','10000','3'); insert into optionconfiguration (id,fieldid,optionid,fieldconfig,sequence) values ('10305','issuetype','10004','10000','4');
  3. Restart JIRA.

Updated on April 2, 2025

Still need help?

The Atlassian Community is here for you.