Import Error: No module named google.cloud when I tried to import the BigQuery

3 views
Skip to first unread message

Qaisar Tariq via StackOverflow

unread,
Apr 25, 2017, 4:52:05 PM4/25/17
to google-appengin...@googlegroups.com

When I try to use this statement in Google App Engine

from google.cloud import big query

It produces the error No Module Named Cloud but it runs fine and update the BigQuery tables if I run it from local machine.

I want to make it a cron job on Google App Engine but this is not working.

Environment: I am in the Standard Environment and its Python 2.7. I am not running the App Engine SDK development Server, I am deploying the App live.

My Code is:

 import time
 import uuid
 from google.cloud import bigquery
 client = bigquery.Client()
 jobid = "jid" + str(uuid.uuid4())
 query = "Select * FROM Table"
 job = client.run_async_query(jobid, query)

When I run the Command gcloud app browse, it opens a Browser and gives the following error:

Error: Server Error 
The server encountered an error and could not complete your request.[![Error Trace][1]][1]

enter image description here



Please DO NOT REPLY directly to this email but go to StackOverflow:
http://stackoverflow.com/questions/43125078/import-error-no-module-named-google-cloud-when-i-tried-to-import-the-bigquery
Reply all
Reply to author
Forward
0 new messages