Go API problem with Google Cloud Datastore

I’m trying to follow the installation tutorial at Getting started with the Firestore in Datastore mode API  |  Cloud Datastore Documentation  |  Google Cloud
But for the last step, running the application by “go run tasks.go”, I get the following error:

2017/11/10 13:21:47 Could not create datastore client: dialing: google: could not find default credentials. See https://
アプリケーションのデフォルト認証情報の仕組み  |  Google Cloud for more information.
exit status 1

But, I did not have to set up this credential when following another Datastore tutorial, the Guestbook app. Can someone explain why? (I’m not allowed to post more links but you can google for that tutorial at “Creating a Guestbook Application - Google Cloud Platform”)

I found the answer here:

However there was another problem when continuing on with the guide:
“Failed to create task: rpc error: code = NotFound desc = The project [project_name] does not exist or it does not contain an active Cloud Datastore database.”

Edit: ^ I apparently had to re-set DATASTORE_PROJECT_ID to a new project instead of an existent one.

This topic was automatically closed 90 days after the last reply. New replies are no longer allowed.