Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix DeadlineExceededErrors for leaderboard page #29

Open
sjaensch opened this issue Mar 16, 2017 · 0 comments
Open

Fix DeadlineExceededErrors for leaderboard page #29

sjaensch opened this issue Mar 16, 2017 · 0 comments

Comments

@sjaensch
Copy link
Contributor

We're seeing a couple of DeadlineExceededError: The overall deadline for responding to the HTTP request was exceeded. entries in our error log; full stacktrace below. We'll need to find a way to make the leaderboard calculation more efficient. Relevant Google documentation.

Traceback (most recent call last):
  File "/base/data/home/runtimes/python27/python27_lib/versions/1/google/appengine/runtime/wsgi.py", line 267, in Handle
	result = handler(dict(self._environ), self._StartResponse)
  File "/base/data/home/apps/s~yelplove/1-7-1.399540497034144168/lib/flask/app.py", line 1836, in __call__
	return self.wsgi_app(environ, start_response)
  File "/base/data/home/apps/s~yelplove/1-7-1.399540497034144168/lib/flask/app.py", line 1817, in wsgi_app
	response = self.full_dispatch_request()
  File "/base/data/home/apps/s~yelplove/1-7-1.399540497034144168/lib/flask/app.py", line 1475, in full_dispatch_request
	rv = self.dispatch_request()
  File "/base/data/home/apps/s~yelplove/1-7-1.399540497034144168/lib/flask/app.py", line 1461, in dispatch_request
	return self.view_functions[rule.endpoint](**req.view_args)
  File "/base/data/home/apps/s~yelplove/1-7-1.399540497034144168/util/decorators.py", line 19, in decorated_view
	return func(*args, **kwargs)
  File "/base/data/home/apps/s~yelplove/1-7-1.399540497034144168/views/web.py", line 136, in leaderboard
	top_lovers, top_lovees = logic.love_count.top_lovers_and_lovees(utc_week_start, dept=department)
  File "/base/data/home/apps/s~yelplove/1-7-1.399540497034144168/logic/love_count.py", line 26, in top_lovers_and_lovees
	employee = employee_key.get()
  File "/base/data/home/runtimes/python27/python27_lib/versions/1/google/appengine/ext/ndb/key.py", line 572, in get
	return self.get_async(**ctx_options).get_result()
  File "/base/data/home/runtimes/python27/python27_lib/versions/1/google/appengine/ext/ndb/tasklets.py", line 383, in get_result
	self.check_success()
  File "/base/data/home/runtimes/python27/python27_lib/versions/1/google/appengine/ext/ndb/tasklets.py", line 378, in check_success
	self.wait()
  File "/base/data/home/runtimes/python27/python27_lib/versions/1/google/appengine/ext/ndb/tasklets.py", line 362, in wait
	if not ev.run1():
  File "/base/data/home/runtimes/python27/python27_lib/versions/1/google/appengine/ext/ndb/eventloop.py", line 268, in run1
	delay = self.run0()
  File "/base/data/home/runtimes/python27/python27_lib/versions/1/google/appengine/ext/ndb/eventloop.py", line 230, in run0
	callback(*args, **kwds)
  File "/base/data/home/runtimes/python27/python27_lib/versions/1/google/appengine/ext/ndb/tasklets.py", line 414, in _help_tasklet_along
	try:
DeadlineExceededError: The overall deadline for responding to the HTTP request was exceeded.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant