python - Creating dataframe from json not always working -
i'm trying run code create data frame json link. sometimes, code run. other times, error message (below). i'm not sure why occurs, though code same. import requests import json url = "http://stats.nba.com/stats/leaguedashplayerstats?college=&conference=&country=&datefrom=&dateto=&division=&draftpick=&draftyear=&gamescope=&gamesegment=&height=&lastngames=0&leagueid=00&location=&measuretype=advanced&month=0&opponentteamid=0&outcome=&poround=0&paceadjust=n&permode=totals&period=0&playerexperience=&playerposition=&plusminus=n&rank=n&season=2016-17&seasonsegment=&seasontype=regular+season&shotclockrange=&starterbench=&teamid=0&vsconference=&vsdivision=&weight=" jd = requests.get(url).json() df = [] item in requests.get(url).json()['resultsets']: print("got here") row_df = [] row in item['rowset...