Python command jira.search_issues: Warning Connection aborted

Cyril Frelet April 28, 2021

Hi,
I run the following code and I get many Warnings. Finally the results goes out but it seems particularly slow.

 

from jira import JIRA
import urllib3

if __name__ == "__main__":
loginJira = sys.argv[1]
passwordJira = sys.argv[2]
urllib3.disable_warnings(urllib3.exceptions.InsecureRequestWarning)
options = {"server": "https://jira.mycloud.xxx.com", "verify": False}

jira = JIRA(options, basic_auth=(loginJira, passwordJira))

print(f"---- Loading issues from JIRA ---- {str(datetime.datetime.now())}")
issues = jira.search_issues('project=PCKINO or project=PCKBAU or project=NEX', maxResults=False)

 The data get extracted when I run that, but I also get Warnings that keep repeating:

WARNING:root:('Connection aborted.', RemoteDisconnected('Remote end closed connection without response',)) while doing GET https://jira.mycloud.xxx.com/rest/api/2/search [{'params': {'jql': 'project=PCKINO or project=PCKBAU or project=NEX', 'startAt': 1250, 'validateQuery': True, 'fields': [], 'expand': None, 'maxResults': 50}, 'headers': {'User-Agent': 'python-requests/2.25.1', 'Accept-Encoding': 'gzip, deflate', 'Accept': 'application/json,*.*;q=0.9', 'Connection': 'keep-alive', 'Cache-Control': 'no-cache', 'Content-Type': 'application/json', 'X-Atlassian-Token': 'no-check'}}]

 

0 answers

Suggest an answer

Log in or Sign up to answer