Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

docs: Add the firestore_setup_client_create_with_project_id region tag #8251

Merged
merged 4 commits into from
Aug 11, 2022
Merged
Changes from 3 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 3 additions & 1 deletion firestore/cloud-client/snippets.py
Original file line number Diff line number Diff line change
Expand Up @@ -21,12 +21,14 @@

def quickstart_new_instance():
# [START firestore_setup_client_create]
# [START firestore_setup_client_create_with_project_id]
from google.cloud import firestore

# The `project` parameter is optional and represents which project the client
# will act on behalf of. If not supplied, the client falls back to the default
# project inferred from the environment.
db = firestore.Client(project='my-project-id')
# [END firestore_setup_client_create_with_project_id]
# [END firestore_setup_client_create]

return db
Expand Down Expand Up @@ -154,7 +156,7 @@ def to_dict(self):
# [END_EXCLUDE]

def __repr__(self):
return(
return (
f'City(\
name={self.name}, \
country={self.country}, \
Expand Down