title: AttributeError : object has no attribute
body: <p>I got a program from a formerly colleague and now should maintain it. 
  This python script asks our Jira instance with a given jql ( on the API ).
  The return is a list of all issues, which are matching the search criteria.
  But now it's not working, and I receive on the server ( Ubuntu ) and on my local windows PC a Json error message. 
  note : it ran for about a year not, but back then it worked.</p>
  
  <p>Here is what the script looks like : </p>
  
  <pre><code>import json
  import subprocess
  
  jiraSerachUrl = "https://ourJiraInstance.net/rest/api/2/search?jql=key%20=%20%22TEST-123%22"
  jiraResponse = subprocess.Popen(["curl","-l","-s","-u", "jiraUser"+":"+"jiraUserPassword", "-X", "GET", jiraSerachUrl ],stdout=subprocess.PIPE,shell=True).communicate()[0]
  ## shell=True only added for Windows Instance
  print(type(jiraResponse))
  ##print =  &lt;class 'bytes'&gt;
  print(jiraResponse)
  ## print = b''
  jiraJsonResponse = json.loads(jiraResponse.decode('utf-8'))
  print(jiraJsonResponse)
  </code></pre>
  
  <p>The jql/jira search address returns the following (shorted answer, all fields of the task are returned): </p>
  
  <blockquote>
    <p>{"expand":"names,schema","startAt":0,"maxResults":50,"total":1,"issues":
    [{"expand":"operations,versionedRepresentations,editmeta,changelog,transitions,renderedFields",
    "id":"145936","self":"<a href="https://ourJiraInstance.net/rest/api/2/issue/145936" rel="nofollow noreferrer">https://ourJiraInstance.net/rest/api/2/issue/145936</a>","key":"TEST-123","fields":{"parent": ...</p>
  </blockquote>
  
  <p>The Error on the Windows PC is the following</p>
  
  <blockquote>
    <p>Traceback (most recent call last):   File
    "C:\Users\User\Desktop\test.py", line 10, in 
        jiraJsonResponse = json.loads(jiraResponse.decode('utf-8'))   File "C:\Users\User\AppData\Local\Programs\Python\Python35-32\lib\json__init__.py",
    line 319, in loads
        return _default_decoder.decode(s)   File "C:\Users\User\AppData\Local\Programs\Python\Python35-32\lib\json\decoder.py",
    line 339, in decode
        obj, end = self.raw_decode(s, idx=_w(s, 0).end())   File "C:\Users\User\AppData\Local\Programs\Python\Python35-32\lib\json\decoder.py",
    line 357, in raw_decode
        raise JSONDecodeError("Expecting value", s, err.value) from None json.decoder.JSONDecodeError: Expecting value: line 1 column 1 (char
    0)</p>
  </blockquote>
  
  <p>This is the error on the Ubuntu Server ( running the same script )</p>
  
  <blockquote>
    <p>Traceback (most recent call last):   File "searchJira.py", line 33, in
    
        jiraJsonResponse = json.loads(jiraResponse)   File "/usr/lib/python2.7/json/<strong>init</strong>.py", line 338, in loads
        return _default_decoder.decode(s)   File "/usr/lib/python2.7/json/decoder.py", line 366, in decode
        obj, end = self.raw_decode(s, idx=_w(s, 0).end())   File "/usr/lib/python2.7/json/decoder.py", line 384, in raw_decode
        raise ValueError("No JSON object could be decoded") ValueError: No JSON object could be decoded</p>
  </blockquote>
  
  <p>So far I tried to change the Json load to simpleJson, but with the same result.
  Changing the format to which Json should decode ( e.g. unicode ) took no effect. </p>