Commit Graph

55 Commits

Author SHA1 Message Date
Tim Abbott 21c2317bd2 Move callbacks library to tornadoviews.py.
(imported from commit a4e545d82133ae9dc34e283e3bf268225e35f400)
2013-01-10 16:59:36 -05:00
Tim Abbott b93db35e50 return_messages_immediately: Fix using last=None with dont_block.
Previously, if last was None, we wouldn't check dont_block,
server_generation, or any of the other reasons that get_updates might
return immediately, and just unconditionally entered longpolling mode.

In the process, this reorders return_messages_immediately to have
fewer cases and thus be easier to read.

(imported from commit 67803b8bfc7d9c9c1a4d6916eb2fb62664fb35a9)
2013-01-08 18:17:55 -05:00
Tim Abbott 40a3659844 return_messages_immediately: Remove check for clients with no messages.
This check was a workaround for the fact that the browser client
submitted a "last" value of -1.

(imported from commit a668f6a4e7a0c027f1214166a9bbf40d29b5daeb)
2013-01-08 18:17:55 -05:00
Tim Abbott 550bbe92ea get_updates: Move negative last checking to POST processing.
We shouldn't deploy this change until strictly after we deploy

"Fix website improperly submitting a last value of -1."

or we will break website clients.

(imported from commit 7f682ab0f7060b677f53f0a0073faef216f45d00)
2013-01-08 18:17:55 -05:00
Tim Abbott 83abc08315 Move tornado views to their own file.
(imported from commit e0d9182cbc89a16eedd2846fa17cfba482510565)
2013-01-08 16:53:53 -05:00