Skip to content

Commit

Permalink
Remove 'gcloud.datastore.set_defaults'.
Browse files Browse the repository at this point in the history
Also remove symbols imported for conveniences from '_implicit_environ'.
  • Loading branch information
tseaver committed Jul 11, 2015
1 parent ca42fdf commit c16dae4
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 75 deletions.
32 changes: 3 additions & 29 deletions gcloud/datastore/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -18,9 +18,10 @@
>>> from gcloud import datastore
>>> key = datastore.Key('EntityKind', 1234)
>>> client = datastore.Client()
>>> key = client.key('EntityKind', 1234)
>>> entity = datastore.Entity(key)
>>> query = datastore.Query(kind='EntityKind')
>>> query = client.query(kind='EntityKind')
The main concepts with this API are:
Expand Down Expand Up @@ -49,11 +50,6 @@
when race conditions may occur.
"""

from gcloud.datastore._implicit_environ import get_connection
from gcloud.datastore._implicit_environ import get_default_connection
from gcloud.datastore._implicit_environ import get_default_dataset_id
from gcloud.datastore._implicit_environ import set_default_connection
from gcloud.datastore._implicit_environ import set_default_dataset_id
from gcloud.datastore.batch import Batch
from gcloud.datastore.connection import SCOPE
from gcloud.datastore.connection import Connection
Expand All @@ -62,25 +58,3 @@
from gcloud.datastore.key import Key
from gcloud.datastore.query import Query
from gcloud.datastore.transaction import Transaction


def set_defaults(dataset_id=None, connection=None):
"""Set defaults either explicitly or implicitly as fall-back.
Uses the arguments to call the individual default methods
- set_default_dataset_id
- set_default_connection
In the future we will likely enable methods like
- set_default_namespace
:type dataset_id: string
:param dataset_id: Optional. The dataset ID to use as default.
:type connection: :class:`gcloud.datastore.connection.Connection`
:param connection: A connection provided to be the default.
"""
set_default_dataset_id(dataset_id=dataset_id)
set_default_connection(connection=connection)
46 changes: 0 additions & 46 deletions gcloud/datastore/test___init__.py

This file was deleted.

1 comment on commit c16dae4

@dhermes
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This commit LGTM

Please sign in to comment.