tornado: Move zerver.tornadoviews to zerver.tornado.views.

This furthers the overall goal of moving all the Tornado-specific code
to zerver/tornado/.
This commit is contained in:
Tim Abbott 2016-11-26 21:50:54 -08:00
parent 169d404579
commit 1fcf2ff525
6 changed files with 9 additions and 9 deletions

View File

@ -23,7 +23,7 @@ paths will be familiar to Django developers.
* `zerver/views/webhooks/` Webhook views for [Zulip integrations](integration-guide.html).
* `zerver/tornadoviews.py` Tornado views.
* `zerver/tornado/views.py` Tornado views.
* `zerver/worker/queue_processors.py` [Queue workers](queuing.html).

View File

@ -290,7 +290,7 @@ def build_custom_checkers(by_lang):
# are already captured
('zerver/middleware.py',
'return json_error(exception.to_json_error_msg(), status=status_code)'),
('zerver/tornadoviews.py', 'return json_error(result["message"])'),
('zerver/tornado/views.py', 'return json_error(result["message"])'),
('zerver/views/invite.py',
'return json_error(data=error_data, msg=ret_error)'),
('zerver/views/streams.py', 'return json_error(property_conversion)'),

View File

@ -64,7 +64,7 @@ from zerver.lib.validator import (
from zerver.views.events_register import _default_all_public_streams, _default_narrow
from zerver.tornadoviews import get_events_backend
from zerver.tornado.views import get_events_backend
from collections import OrderedDict
import mock

View File

@ -29,7 +29,7 @@ from tornado.web import Application
from tornado.websocket import websocket_connect
from zerver.tornado.application import create_tornado_application
from zerver.tornadoviews import get_events_backend
from zerver.tornado.views import get_events_backend
from six.moves.http_cookies import SimpleCookie

View File

@ -13,6 +13,7 @@ from zerver.lib.integrations import WEBHOOK_INTEGRATIONS
from django.contrib.auth.views import (login, password_reset,
password_reset_done, password_reset_confirm, password_reset_complete)
import zerver.tornado.views
import zerver.views
import zerver.views.auth
import zerver.views.zephyr
@ -22,7 +23,6 @@ import zerver.views.integrations
import confirmation.views
from zerver.lib.rest import rest_dispatch
from zerver import tornadoviews
# NB: There are several other pieces of code which route requests by URL:
#
@ -273,10 +273,10 @@ v1_api_and_json_patterns = [
url(r'^register$', rest_dispatch,
{'POST': 'zerver.views.events_register.api_events_register'}),
# events -> zerver.tornadoviews
# events -> zerver.tornado.views
url(r'^events$', rest_dispatch,
{'GET': 'zerver.tornadoviews.get_events_backend',
'DELETE': 'zerver.tornadoviews.cleanup_event_queue'}),
{'GET': 'zerver.tornado.views.get_events_backend',
'DELETE': 'zerver.tornado.views.cleanup_event_queue'}),
]
# Include the dual-use patterns twice
@ -334,7 +334,7 @@ for app_name in settings.EXTRA_INSTALLED_APPS:
# Tornado views
urls += [
# Used internally for communication between Django and Tornado processes
url(r'^notify_tornado$', tornadoviews.notify, name='zerver.tornadoviews.notify'),
url(r'^notify_tornado$', zerver.tornado.views.notify, name='zerver.tornado.views.notify'),
]
# Python Social Auth