Home > other >  Json error, a great god answers
Json error, a great god answers

Time:11-13

Json. The decoder. JSONDecodeError: Expecting value: line 1 column 1 (char 0)
Report this error

The import requests
The response=requests. Get (" https://kyfw.12306.cn/otn/leftTicket/query? LeftTicketDTO. Train_date=2020-11-20 & amp; LeftTicketDTO. From_station=HFH& LeftTicketDTO. To_station=BJP& Purpose_codes=ADULT ")
Result=response. Json ()
Result=result [' data '] [' result ']
For I in result:
Print (I)


This is calling from code, a great god answers how to modify

CodePudding user response:

To ask, I also want to ask, specific what circumstance can use json () method?
  • Related