python导入错误“No module named appengine.ext” [英] python import error "No module named appengine.ext"

查看:134
本文介绍了python导入错误“No module named appengine.ext”的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

运行此代码后,我发现导入错误: -

after runing this code,I found import error:-

from google.appengine.ext import webapp
from google.appengine.ext.webapp.util import run_wsgi_app

class MainPage(webapp.RequestHandler):
    def get(self):
        self.response.headers['Content-Type'] = 'text/plain'
        self.response.out.write('Hello, webapp World!')

application = webapp.WSGIApplication([('/', MainPage)],debug=True)

def main():
    run_wsgi_app(application)

if __name__ == "__main__":
    main()

如何使用google.apengine.ext

how to use google.apengine.ext

推荐答案

它看起来像App Engine SDK没有安装,或者至少Python运行时无法找到它。

It looks like the App Engine SDK is not installed, or at least the Python runtime cannot find it.

请阅读并遵循此处的说明: https://cloud.google.com/appengine/do wnloads#Google_App_Engine_SDK_for_Python

read and follow the instructions here: https://cloud.google.com/appengine/downloads#Google_App_Engine_SDK_for_Python

他们告诉你,如何安装App Engine SDK for Python。

They tell you, how to install App Engine SDK for Python.

这篇关于python导入错误“No module named appengine.ext”的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆