def omdb(title, year):
    params = {'t': title.encode('ascii', 'ignore'),
              'plot': 'full',
              'type': 'movie',
              'tomatoes': 'true'}

    if year:
        params['y'] = year

    url = OMDB_URL + urlencode(params)
    return json.loads(requests.get(url).text)
Setup logging for CLI use.
dataset/ETHPy150Open iCHAIT/moviemon/moviemon/moviemon.py/omdb--crossover with--dataset/ETHPy150Open tony/tmuxp/tmuxp/cli.py/setup_logger