GAE Standard | Local Dev | Python37: google.appengine.api not found

115 views
Skip to first unread message

Yanay Lehavi

unread,
Nov 24, 2019, 9:08:57 PM11/24/19
to Google App Engine
I see a number of threads on this in git etc. but they all seem unresolved:

>>> import google.appengine.api

Traceback (most recent call last):

  File "<stdin>", line 1, in <module>

ModuleNotFoundError: No module named 'google'

>>> 


In the above mentioned threads, some people suggested various env vars, none of which I have, nor ever needed... (been developing GAE locally for a long time).
My platform: Mac Catalina.
Anyone knows how to resolve this?
Many thanks

Ryan B

unread,
Nov 25, 2019, 12:58:12 PM11/25/19
to Google App Engine
hi Yanay! the classic App Engine APIs in google.appengine.api aren't available in the Python 3 runtime. More details: https://cloud.google.com/appengine/docs/standard/python3/python-differences#app_engine_apis

Andrew Gorcester

unread,
Nov 25, 2019, 3:00:22 PM11/25/19
to google-a...@googlegroups.com
Hi Yanay,

I'm an engineer at Google working on making the migration from GAE Python 2.7 (a Gen 1 runtime) to Python 3.7 (a Gen 2 runtime) clearer for users. In addition to the page Ryan linked above which explains the differences, we have also recently published this migration homepage with some tutorials and examples: https://cloud.google.com/appengine/docs/standard/python/migrate-to-python3/

Please take a look and let us know if you need more specific information. Thanks!

--
You received this message because you are subscribed to the Google Groups "Google App Engine" group.
To unsubscribe from this group and stop receiving emails from it, send an email to google-appengi...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/google-appengine/2fbbae44-76e6-4e28-9cc6-3c4bfe50f074%40googlegroups.com.

Yanay Lehavi

unread,
Nov 25, 2019, 8:43:57 PM11/25/19
to Google App Engine
Thank you Andrew. We have migrated most of our stuff to py37 and everything works very well so far. I'm familiar with the documentation. The reason I started this thread is I'm trying to migrate automated email (which in 27 call the appengine.api package). It looks like there's no way to send email under 37?

Thanks!


On Monday, November 25, 2019 at 12:00:22 PM UTC-8, Andrew Gorcester wrote:
Hi Yanay,

I'm an engineer at Google working on making the migration from GAE Python 2.7 (a Gen 1 runtime) to Python 3.7 (a Gen 2 runtime) clearer for users. In addition to the page Ryan linked above which explains the differences, we have also recently published this migration homepage with some tutorials and examples: https://cloud.google.com/appengine/docs/standard/python/migrate-to-python3/

Please take a look and let us know if you need more specific information. Thanks!

On Mon, Nov 25, 2019 at 9:58 AM Ryan B <goo...@ryanb.org> wrote:
hi Yanay! the classic App Engine APIs in google.appengine.api aren't available in the Python 3 runtime. More details: https://cloud.google.com/appengine/docs/standard/python3/python-differences#app_engine_apis


On Sunday, November 24, 2019 at 6:08:57 PM UTC-8, Yanay Lehavi wrote:
I see a number of threads on this in git etc. but they all seem unresolved:

>>> import google.appengine.api

Traceback (most recent call last):

  File "<stdin>", line 1, in <module>

ModuleNotFoundError: No module named 'google'

>>> 


In the above mentioned threads, some people suggested various env vars, none of which I have, nor ever needed... (been developing GAE locally for a long time).
My platform: Mac Catalina.
Anyone knows how to resolve this?
Many thanks

--
You received this message because you are subscribed to the Google Groups "Google App Engine" group.
To unsubscribe from this group and stop receiving emails from it, send an email to google-a...@googlegroups.com.

Andrew Gorcester

unread,
Nov 25, 2019, 8:47:46 PM11/25/19
to google-a...@googlegroups.com
Unfortunately there is not currently any Google Cloud replacement for the GAE Mail API. We are aware of the gap in our migration story and are working to fix it.

To unsubscribe from this group and stop receiving emails from it, send an email to google-appengi...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/google-appengine/5ee38ced-fcd4-4f8f-bf80-2e1b4b51338f%40googlegroups.com.

Toon Knapen

unread,
Nov 26, 2019, 10:05:33 AM11/26/19
to Google App Engine
There are outside services available as documented in the mail section of https://cloud.google.com/appengine/docs/flexible/python/migrating. Is that covering your need?

Yanay Lehavi

unread,
Nov 26, 2019, 10:52:09 AM11/26/19
to Google App Engine
Thank you Poon, nice catch. I'll wait for GCP, this stuff is too trivial to have to depend on yet another vendor/contract/payment/spam ;)
Reply all
Reply to author
Forward
0 new messages