if len(sys.argv) != 2:
    print('Usage: {0} <http://riak_host:8098/riak/bucket_name>'.format(sys.
        argv[0]))
print('Set riak_host and bucket_name appropriately for your Riak cluster.')
exit(0)
r = requests.get(sys.argv[1] + '?keys=stream')
content = ''
key_count = 0
for chunk in r.iter_content():
    if chunk:
        content += chunk
re.sub('(?=(^|})({.*?})(?={|$))', processChunk, content)
print('Deleted', key_count, 'keys')
How can I delete a Riak bucket in Python?