Commit 59e73138a22c941c90175530f6e55951eea817cc
1 parent
00102915
Exists in
master
and in
1 other branch
- make question GET handler async.
Showing
2 changed files
with
4 additions
and
2 deletions
Show diff stats
BUGS.md
@@ -5,6 +5,9 @@ | @@ -5,6 +5,9 @@ | ||
5 | 5 | ||
6 | # TODO | 6 | # TODO |
7 | 7 | ||
8 | +- max tries nas perguntas. | ||
9 | +- botão não sei... | ||
10 | +- mostrar feedback/solucoes quando acerta, ou excede max tries. | ||
8 | - mostrar icon "loading..." enquanto está a corrigir uma pergunta. | 11 | - mostrar icon "loading..." enquanto está a corrigir uma pergunta. |
9 | - Criar outra estrutura organizada em capítulos (conjuntos de tópicos). Permitir capítulos de capítulos, etc. talvez usar grafos de grafos... | 12 | - Criar outra estrutura organizada em capítulos (conjuntos de tópicos). Permitir capítulos de capítulos, etc. talvez usar grafos de grafos... |
10 | - each topic only loads a sample of K questions (max) in random order. | 13 | - each topic only loads a sample of K questions (max) in random order. |
serve.py
@@ -77,7 +77,6 @@ class LoginHandler(BaseHandler): | @@ -77,7 +77,6 @@ class LoginHandler(BaseHandler): | ||
77 | def get(self): | 77 | def get(self): |
78 | self.render('login.html', error='') | 78 | self.render('login.html', error='') |
79 | 79 | ||
80 | - # @gen.coroutine | ||
81 | async def post(self): | 80 | async def post(self): |
82 | uid = self.get_body_argument('uid') | 81 | uid = self.get_body_argument('uid') |
83 | pw = self.get_body_argument('pw') | 82 | pw = self.get_body_argument('pw') |
@@ -213,7 +212,7 @@ class QuestionHandler(BaseHandler): | @@ -213,7 +212,7 @@ class QuestionHandler(BaseHandler): | ||
213 | 212 | ||
214 | # --- get question to render | 213 | # --- get question to render |
215 | @tornado.web.authenticated | 214 | @tornado.web.authenticated |
216 | - def get(self): | 215 | + async def get(self): |
217 | logging.debug('QuestionHandler.get()') | 216 | logging.debug('QuestionHandler.get()') |
218 | user = self.current_user | 217 | user = self.current_user |
219 | 218 |