client = storage.Client.from_service_account_json('client-secret.json', project=PROJECT_NAME)
bucket = client.get_bucket(BUCKET_NAME)
with client.batch():
for i in range(10):
with open('base.py', 'rb') as my_file:
blob = storage.Blob('/test/{}'.format(i), bucket)
blob.upload_from_file(my_file, client=client)
This, of course, won't work because is using client._base_connection instead of client.current_batch.