def resolve_woeid(woeid):
    values = {
        'app_id': YAHOO_APP_ID,
        'woeid': woeid
    }
    url = WHERE_API_RESOLVE_URL % values
    response = requests.get(url)
    data = json.loads(response.text)
    try:
        place = data['place']
        place_name = place['name']
        if place['admin1']:
            place_name += ', ' + place['admin1']
        if place['country']:
            place_name += ', ' + place['country']
    except __HOLE__, k:
        place_name = None
    return place_name
dataset/ETHPy150Open hacktoolkit/hacktoolkit/apis/yahoo/geo/geoplanet/geoplanet.py/resolve_woeid