Search code examples
pythongoogle-app-enginegoogle-cloud-datastore

App Engine local environment shows incorrect data


Just started using Google Cloud SDK Shell after using the older, gui-based, version. I have multiple projects under development, if that matters. Here's what I do

run gcloud SDK shell (click on the icon!)
cd \myproject
dev_appserver.py app.yaml

In the browser (Chrome),

browse to http://localhost:8000/datastore

Under Datastore Viewer, I see 'tables' from a completely different project (say, myotherproject)

Under Datastore Indexes, I see 'indexes' from the correct project (myproject)

Under Task Queues, I see the correct queues listed (I have specified different queues setup for parts of myproject)

Everything works fine for myotherproject. So, is there something I am missing to get the Datastore Viewer to show the correct 'tables'?

Many thanks, David

Edit: no matter what project I run, Datastore Viewer shows the same data (from myotherproject) but Datastore Indexes show the correct indexes.

Edit: Windows 8.1, Python v2.7.13:a06454b1afa1

Edit: further questions 1) does gcloud sdk use a different datastore from the original app engine sdk? 2) if so, where is it by default or do I have to define it upfront?


Solution

  • Thanks to everyone for their help with this. It appears GCloud uses one datastore for all projects so the --datastore_path is not really optional when you have multiple paths. However, I kept getting errors with --datastore_path so I went with the following...

    dev_appserver.py --storage_path=c:\gcdata\projectname app.yaml
    

    Yes, could have been c:\temp but this gives me separate 'databases', one for each project.

    Note also that GCloud SDK does not use the same data as the original App Engine SDK grrrrrr!