Skip to content

Commit

Permalink
docs(bigquery): add docstring for conflict exception (#171)
Browse files Browse the repository at this point in the history
* docs(bigquery): add docstring for conflict exception

* docs(bigquery): nit
  • Loading branch information
HemangChothani committed Jul 20, 2020
1 parent f9f2f45 commit 9c3409b
Showing 1 changed file with 12 additions and 0 deletions.
12 changes: 12 additions & 0 deletions google/cloud/bigquery/client.py
Expand Up @@ -441,6 +441,10 @@ def create_dataset(
google.cloud.bigquery.dataset.Dataset:
A new ``Dataset`` returned from the API.
Raises:
google.cloud.exceptions.Conflict:
If the dataset already exists.
Example:
>>> from google.cloud import bigquery
Expand Down Expand Up @@ -496,6 +500,10 @@ def create_routine(
Returns:
google.cloud.bigquery.routine.Routine:
A new ``Routine`` returned from the service.
Raises:
google.cloud.exceptions.Conflict:
If the routine already exists.
"""
reference = routine.reference
path = "/projects/{}/datasets/{}/routines".format(
Expand Down Expand Up @@ -540,6 +548,10 @@ def create_table(self, table, exists_ok=False, retry=DEFAULT_RETRY, timeout=None
Returns:
google.cloud.bigquery.table.Table:
A new ``Table`` returned from the service.
Raises:
google.cloud.exceptions.Conflict:
If the table already exists.
"""
table = _table_arg_to_table(table, default_project=self.project)

Expand Down

0 comments on commit 9c3409b

Please sign in to comment.