Python Forum
JSONDecodeError: Expecting value
Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
JSONDecodeError: Expecting value
#1
Hi,

I'm trying to read json content from a url, however, it is displaying the below error in spite of status 200 (<Response [200]>).

JSONDecodeError: Expecting value

Below is the code:

jUrl_dummy = 'https://abc.dummy.com/rest/api/latest/search?fields=%s&query=%s'
fields_dummy = 'key,summary'
username = credentials.login['username']
password = credentials.login['password']
query_dummy = ('project = xxx')
r_dummy = requests.get(jUrl_dummy % (fields_dummy, query_dummy), auth = (username, password))
print(r_dummy)
j_dummy = r_dummy.json() --> This gives the error
Can someone please help with the resolution?
Larz60+ write Mar-07-2022, 01:54 PM:
Please post all code, output and errors (it it's entirety) between their respective tags. Refer to BBCode help topic on how to post. Use the "Preview Post" button to make sure the code is presented as you expect before hitting the "Post Reply/Thread" button.
Fixed for you this time. Please use BBCodes on future posts.
Reply


Messages In This Thread
JSONDecodeError: Expecting value - by mehtamonita - Mar-07-2022, 10:05 AM
RE: JSONDecodeError: Expecting value - by bowlofred - Mar-07-2022, 04:24 PM

Possibly Related Threads…
Thread Author Replies Views Last Post
  How can i fix json.decoder.JSONDecodeError ? JgKSuperstar 9 4,737 Oct-30-2021, 11:23 PM
Last Post: JgKSuperstar
  Problems with JSONDecodeError arsouzaesilva 0 1,456 Sep-22-2021, 06:33 PM
Last Post: arsouzaesilva
  Pyspark SQL Error - mismatched input 'FROM' expecting <EOF> Ariean 3 48,224 Nov-20-2020, 03:49 PM
Last Post: Ariean
  TypeError: size; expecting a recognized type filling string dict a11_m11 0 2,569 Feb-10-2020, 08:26 AM
Last Post: a11_m11

Forum Jump:

User Panel Messages

Announcements
Announcement #1 8/1/2020
Announcement #2 8/2/2020
Announcement #3 8/6/2020