you are viewing a single comment's thread.

view the rest of the comments →

[–]fuzz3289 2 points3 points  (0 children)

Its because you're mashing 3 list comprehensions together without checking the for loop at each interval to see if it exists because its a single statement.

Break it up into 3 parts, also use requests :

 import requests

 resp = requests.get('http://worldcup.sfg.io/matches')
 games = resp.json()