Google app engine Google App Engine在此服务器上找不到请求的URL/并非始终如此
三天前,我用Webapp2创建了一个谷歌应用程序引擎项目,一切都很好,但今天(现在)我惊讶于它有时会说它行为不端 在此服务器上找不到请求的URL/ 然后,如果我在浏览器中重新加载url多次,比如10次。我可以看到我的网站 它将用户重定向到他们的Google帐户,然后检查用户是否已注册,并提供个性化内容或信息。尝试在它导致的浏览器中重新加载 在此服务器上找不到请求的URL/ 发生了什么事?这是因为在做谷歌云项目时选择了一个位置,选择中没有非洲,所以我选择了附近的区域 虽然它,如果它加载它可能会检查你的电子邮件是注册第一 这是Google app engine Google App Engine在此服务器上找不到请求的URL/并非始终如此,google-app-engine,google-cloud-platform,webapp2,google-app-engine-python,Google App Engine,Google Cloud Platform,Webapp2,Google App Engine Python,三天前,我用Webapp2创建了一个谷歌应用程序引擎项目,一切都很好,但今天(现在)我惊讶于它有时会说它行为不端 在此服务器上找不到请求的URL/ 然后,如果我在浏览器中重新加载url多次,比如10次。我可以看到我的网站 它将用户重定向到他们的Google帐户,然后检查用户是否已注册,并提供个性化内容或信息。尝试在它导致的浏览器中重新加载 在此服务器上找不到请求的URL/ 发生了什么事?这是因为在做谷歌云项目时选择了一个位置,选择中没有非洲,所以我选择了附近的区域 虽然它,如果它加载它可能会检查
app.yaml
文件:
application: cngiramicroloanscentre
version: alpha
runtime: python27
api_version: 1
threadsafe: yes
handlers:
- url: /
script: cngira.app
login: required
- url: /loanee/.*
script: loanee.app
login: required
- url: /officers
script: officers.app
login: required
- url: /loanees
script: loanees.app
login: required
- url: /loanees/.*
script: loanees.app
login: required
libraries:
- name: webapp2
version: "2.5.2"
- name: jinja2
version: "2.6"
- name: markupsafe
version: "0.15"
在cngira.py
中路由的代码部分是:
....
app= webapp2.WSGIApplication([('/',MainPage)],debug=True)
课程主页是:
class MainPage(webapp2.RequestHandler):
"""docstring for MainPage"""
def get(self):
user=users.get_current_user()
user_email=user.email()
fetched_user=(ndb.Key("Officer",user_email)).get()
if(fetched_user==None and user_email != "johnnnoni@gmail.com" and user_email != "barakarichard1992@gmail.com"):
self.response.out.write("Sorry you are not authorised to access this place yet consult the authorised to add you to add you!! "+user_email)
else:
template_in=template_env.get_template("templates/index.html")
if(user_email=="johnnnoni@gmail.com" or user_email == "barakarichard1992@gmail.com"):
dictionary_to_pass={"navigations":navigations}
self.response.out.write(template_in.render(dictionary_to_pass))
else:
self.response.out.write(template_in.render( { "navigations":navigation_for_officer } ))
本例中显示的404页面不是来自应用程序的404错误的典型页面,而是“坏机器人”
但将应用程序配置+代码克隆为新的(临时的)只是重复检查的项目总是需要尝试的——如果新项目按预期工作,则可能需要联系谷歌的支持人员来修复旧项目。除非您显示一些代码,否则无法猜测……问题是我甚至不知道应该发送哪种代码<代码>应用程序yaml或?因为它起作用,然后它不起作用,然后它起作用,然后它不起作用…它与代码有关吗?显示“app.yaml”和“/”路由的处理程序。我添加了…@mihailrussut 404错误页由GAE填写,而不是由您的应用程序填写。这通常表示无法找到(或启动?)要将请求传递给的应用程序实例。你在你的应用程序中看到了什么?