AutoRclone
AutoRclone copied to clipboard
Exceeded the maximum calls(1000) in a single batch request.
sudo python3 add_to_google_group.py -g [email protected]
<googleapiclient.discovery.Resource object at 0x7fc9ef262208>
Readying accounts |########################## | 1000/1200Traceback (most recent call last):
File "add_to_google_group.py", line 68, in <module>
batch.add(group.members().insert(groupKey=gaddr, body=body))
File "/usr/local/lib/python3.6/dist-packages/googleapiclient/_helpers.py", line 134, in positional_wrapper
return wrapped(*args, **kwargs)
File "/usr/local/lib/python3.6/dist-packages/googleapiclient/http.py", line 1400, in add
% MAX_BATCH_LIMIT
googleapiclient.errors.BatchError: <BatchError "Exceeded the maximum calls(1000) in a single batch request.">
I struggled with this for a while.
I solved this by editing http.py and changing MAX_BATCH_LIMIT = 1000 to MAX_BATCH_LIMIT = 1200