Get hands-on experience with 20+ free Google Cloud products and $300 in free credit for new customers.

Do I still need Python27 in my dev. env. for Python3 apps that use Bundle Services?

This is something I do have in my development environment, but I'm not sure whether (in the latest releases of gcloud CLI/SDK) it is still required.

- I have appengine-python-standard>=1.0.0 in my requirements.txt
- I have app_engine_apis: true in my app.yaml
- and I have the environment variable CLOUDSDK_DEVAPPSERVER_PYTHON set to the path where Python27 is installed

Is the latter still required in latest versions of gcloud if one uses (Legacy?) Bundled Services in applications that are now running on Python3?

By the way, I work on Windows, so I also have to use this patch  from @NoCommandLine . Is that still required as well?

Thanks.

 

 

Solved Solved
0 3 198
1 ACCEPTED SOLUTION

I would say, Yes to both questions.

...From the current documentation (the page shows it was last updated on  2023-10-02 UTC)

A) Note: The dev_appserver tool does not support development of Python 3 apps on Windows.
i) This means you still need our Patch if you want to run your Apps with dev_appserver.py on Windows

ii) I'm not aware that the latest release of gcloud CLI/SDK has changed the requirement that using legacy (bundled services) APIs still requires running your App with dev_appserver.py

B)

  1. Verify that you have installed both Python interpreters on your machine:

    Both Python interpreters are required even if your app is written in another runtime or language version.

  2. Set the CLOUDSDK_DEVAPPSERVER_PYTHON environment variable in your shell to the path of your Python 2 interpreter.

 

..... NoCommandLine ......
 https://nocommandline.com
A GUI for Google App Engine

View solution in original post

3 REPLIES 3

I would say, Yes to both questions.

...From the current documentation (the page shows it was last updated on  2023-10-02 UTC)

A) Note: The dev_appserver tool does not support development of Python 3 apps on Windows.
i) This means you still need our Patch if you want to run your Apps with dev_appserver.py on Windows

ii) I'm not aware that the latest release of gcloud CLI/SDK has changed the requirement that using legacy (bundled services) APIs still requires running your App with dev_appserver.py

B)

  1. Verify that you have installed both Python interpreters on your machine:

    Both Python interpreters are required even if your app is written in another runtime or language version.

  2. Set the CLOUDSDK_DEVAPPSERVER_PYTHON environment variable in your shell to the path of your Python 2 interpreter.

 

..... NoCommandLine ......
 https://nocommandline.com
A GUI for Google App Engine

Thank you @NoCommandLine .

I supposed the best way to know when that changes (besides asking here) is to check or subscribe to this:
https://groups.google.com/g/google-cloud-sdk-announce
Is that right?

 

That or you bookmark the release notes url and check it regularly.

 

..... NoCommandLine ......
 https://nocommandline.com
A GUI for Google App Engine