Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(736)

Unified Diff: appengine/chromium_cq_status/handlers/stats_viewer.py

Issue 2111713004: Teach CQ status app to check login status of users. (Closed) Base URL: https://chromium.googlesource.com/infra/infra.git@master
Patch Set: Review and tests. Created 4 years, 6 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: appengine/chromium_cq_status/handlers/stats_viewer.py
diff --git a/appengine/chromium_cq_status/handlers/stats_viewer.py b/appengine/chromium_cq_status/handlers/stats_viewer.py
index df21b2b3fc497d6f72473bbf73f882fdb996a708..37ce72c48e6357321cd900929ccc36089070de02 100644
--- a/appengine/chromium_cq_status/handlers/stats_viewer.py
+++ b/appengine/chromium_cq_status/handlers/stats_viewer.py
@@ -4,7 +4,9 @@
import webapp2
-from shared.utils import minutes_per_day
+from shared import utils
+
+minutes_per_day = 24 * 60
period_config = {
'15-minutely': {
@@ -30,6 +32,7 @@ period_config = {
}
class StatsViewer(webapp2.RequestHandler): # pragma: no cover
+ @utils.read_access
def get(self, project, period):
assert period in period_config
config = period_config[period]
« no previous file with comments | « appengine/chromium_cq_status/handlers/stats_query.py ('k') | appengine/chromium_cq_status/handlers/test/post_test.py » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698