def read(config, args):
    pp = pprint.PrettyPrinter()
    url = config['url'] + "/api/session/"

    if (args['all'] is False) and (args['session'] is None):
        print("No session(s) specified to read. Use -h to see usage.")
        return
    elif args['session'] is not None:
        url += args['session'] + "/"

    token = auth.get_token(config)
    r = requests.get(url, headers={"X-Auth-Token": token})
    if r.status_code != 200:
        print((r.status_code) % "API returned status code %s")
        sys.exit(1)
    else:
        pp.pprint(json.loads(r.content))
dataset/ETHPy150Open emccode/heliosburn/heliosburn/hbcli/controllers/session.py/read/swapped operands of `%`