2016-05-30 16 views
0

Python-Jira APIを使用してJiraの問題を作成しようとしていますが、ソースと地域のフィールドに画面エラーが表示されます。ソースと地域フィールドのPython Jira API画面エラー

エラー:

Exception Value:  
JiraError HTTP 400 
text: Field 'source' cannot be set. It is not on the appropriate screen, or unknown. 
url: http://jira.corp.inmobi.com/rest/api/2/issue 
response headers = {'X-AUSERNAME': 'Vivek.Sinha', 'X-ASEN': 'SEN-2505611', 'X-Content-Type-Options': 'nosniff', 'Content-Encoding': 'gzip', 'Transfer-Encoding': 'chunked', 'X-Seraph-LoginReason': 'OK', 'Vary': 'User-Agent', 'X-AREQUESTID': '777x24903741x3', 'X-ASESSIONID': '6dg96h', 'Connection': 'close', 'Cache-Control': 'no-cache, no-store, no-transform', 'Date': 'Mon, 30 May 2016 12:57:34 GMT', 'Server': 'Apache-Coyote/1.1', 'Content-Type': 'application/json;charset=UTF-8'} 
response text = {"errorMessages":[],"errors":{"source":"Field 'source' cannot be set. It is not on the appropriate screen, or unknown."}} 

コード:

def create(request): 
    if 'name' in request.GET: 
      n=request.GET['name'] 
      options={'server':'http://jira.com'} 
      jira=JIRA(options,basic_auth=('username','passwd')) 
      root_dict={ 
      'project':{'key':'TS'}, 
      'issuetype':{'name':'Issue'}, 
      'summary':'Test', 
      'description':'Test', 
      'source':[{'name':'Walk-ups'}], 
      'type':{'name':p}, 
      'region':{'name':'INDIA'}, 
      } 
      my_issue=jira.create_issue(fields=root_dict) 

答えて