Pub/Sub empty topic batch fails #1955
Labels
api: pubsub
Issues related to the Pub/Sub API.
type: bug
Error or flaw in code with unintended results or allowing sub-optimal usage patterns.
fails if rows is empty:
Traceback (most recent call last):
…
File "/usr/local/lib/python2.7/dist-packages/gcloud/pubsub/topic.py", line 420, in exit
self.commit()
File "/usr/local/lib/python2.7/dist-packages/gcloud/pubsub/topic.py", line 449, in commit
message_ids = api.topic_publish(self.topic.full_name, self.messages[:])
File "/usr/local/lib/python2.7/dist-packages/gcloud/pubsub/connection.py", line 205, in topic_publish
method='POST', path='/%s:publish' % (topic_path,), data=data)
File "/usr/local/lib/python2.7/dist-packages/gcloud/connection.py", line 344, in api_request
error_info=method + ' ' + url)
BadRequest: 400 The value for message_count is too small. You passed 0 in the request, but the minimum value is 1. (POST https://pubsub.googleapis.com/v1/projects/karos-api/topics/api-prod:publish)
The text was updated successfully, but these errors were encountered: