Skip to content

Commit

Permalink
Document exceptions (currently) raised from 'Connection.create_bucket'.
Browse files Browse the repository at this point in the history
Note that #164 would change this (by adding fine-grained exceptions
for 409, 401, etc.).

Fixes #166 (but should be revisited if #164 lands).
  • Loading branch information
tseaver committed Oct 31, 2014
1 parent d4c46af commit c9f86ab
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions gcloud/storage/connection.py
Original file line number Diff line number Diff line change
Expand Up @@ -338,6 +338,8 @@ def create_bucket(self, bucket):
:rtype: :class:`gcloud.storage.bucket.Bucket`
:returns: The newly created bucket.
:raises: :class:`gcloud.storage.exceptions.ConnectionError` if
there is a confict (bucket already exists, invalid name, etc.)
"""
bucket = self.new_bucket(bucket)
response = self.api_request(method='POST', path='/b',
Expand Down

0 comments on commit c9f86ab

Please sign in to comment.