import requests
import json


def get_json_data(url):
    """Makes a HTTP request with the given url and returns json data as a python object"""
    raw_json = requests.get(url)
    try:
        json_data = json.loads(raw_json.content)
    except json.JSONDecodeError:
        print("Error: Got non valid JSON document from", url)
        raise
    return json_data