appengine icon indicating copy to clipboard operation
appengine copied to clipboard

ModuleNotFoundError: No module named 'setup'

Open tokamak-git opened this issue 6 years ago • 3 comments

Thank you for your time in advance The same problem of #74 seems to happen again with Cloud SDK version 190.0.1

Found this error when running goapp serve:

File "/opt/google-cloud-sdk/platform/google_appengine/goapp", line 40, in <module>
 from google.appengine.tools import goroots
ImportError: cannot import name goroots

My config:

Installation Root: [/opt/google-cloud-sdk]
Installed Components:
  core: [2018.02.12]
  app-engine-python: [1.9.66]
  app-engine-go: []
  beta: [2017.09.15]
  gsutil: [4.28]
  bq: [2.0.29]

Error when running dev_appserver.py app.yaml

Traceback (most recent call last):
  File "/opt/google-cloud-sdk/bin/dev_appserver.py", line 11, in <module>
    import bootstrapping.bootstrapping as bootstrapping
  File "/opt/google-cloud-sdk/bin/bootstrapping/bootstrapping.py", line 9, in <module>
    import setup
ModuleNotFoundError: No module named 'setup'

Any suggestions on how to proceed

tokamak-git avatar Feb 28 '18 14:02 tokamak-git

Switch to python 2.7 version.

sridharkalaibala avatar Mar 17 '18 07:03 sridharkalaibala

I had the same issue. I fixed it by changing #!/usr/bin/env python to #!/usr/bin/env python2 in the beginning of /opt/google-cloud-sdk/bin/dev_appserver.py .

vendelin8 avatar Jul 03 '18 05:07 vendelin8

Does not solve the issue on Arch. My solution has been using docker to setup a container. That way everything works.

tokamak-git avatar Jul 20 '18 03:07 tokamak-git