チャネルを使用して django のインスタンスを立ち上げようとしています。django runserver を使用してデータを localhost にサーバーすることができる開発環境に正常にデプロイされました。私の製品環境では、mod_proxy_wstunnel を有効にして、apache を proxypass サーバーとして使用しています。サーバーは正常に起動しますが、ブラウザーで開くと、runserver コンソールに次のエラーが表示されます。
2016-06-13 17:20:16,078 - ERROR - http_protocol - Traceback (most recent call last):
File "/opt/anaconda2/lib/python2.7/site-packages/daphne/http_protocol.py", line 108, in process
logger.debug("Upgraded connection %s to WebSocket %s", self.reply_channel, protocol.reply_channel)
AttributeError: 'WebSocketProtocol' object has no attribute 'reply_channel'
Unhandled Error
Traceback (most recent call last):
File "/opt/anaconda2/lib/python2.7/site-packages/twisted/python/log.py", line 101, in callWithLogger
return callWithContext({"system": lp}, func, *args, **kw)
File "/opt/anaconda2/lib/python2.7/site-packages/twisted/python/log.py", line 84, in callWithContext
return context.call({ILogContext: newCtx}, func, *args, **kw)
File "/opt/anaconda2/lib/python2.7/site-packages/twisted/python/context.py", line 118, in callWithContext
return self.currentContext().callWithContext(ctx, func, *args, **kw)
File "/opt/anaconda2/lib/python2.7/site-packages/twisted/python/context.py", line 81, in callWithContext
return func(*args,**kw)
--- <exception caught here> ---
File "/opt/anaconda2/lib/python2.7/site-packages/twisted/internet/posixbase.py", line 597, in _doReadOrWrite
why = selectable.doRead()
File "/opt/anaconda2/lib/python2.7/site-packages/twisted/internet/tcp.py", line 209, in doRead
return self._dataReceived(data)
File "/opt/anaconda2/lib/python2.7/site-packages/twisted/internet/tcp.py", line 215, in _dataReceived
rval = self.protocol.dataReceived(data)
File "/opt/anaconda2/lib/python2.7/site-packages/twisted/protocols/basic.py", line 571, in dataReceived
why = self.lineReceived(line)
File "/opt/anaconda2/lib/python2.7/site-packages/twisted/web/http.py", line 1692, in lineReceived
self.allContentReceived()
File "/opt/anaconda2/lib/python2.7/site-packages/twisted/web/http.py", line 1781, in allContentReceived
req.requestReceived(command, path, version)
File "/opt/anaconda2/lib/python2.7/site-packages/twisted/web/http.py", line 768, in requestReceived
self.process()
File "/opt/anaconda2/lib/python2.7/site-packages/daphne/http_protocol.py", line 143, in process
self.basic_error(500, b"Internal Server Error", "HTTP processing error")
File "/opt/anaconda2/lib/python2.7/site-packages/daphne/http_protocol.py", line 246, in basic_error
}).encode("utf8"),
File "/opt/anaconda2/lib/python2.7/site-packages/daphne/http_protocol.py", line 206, in serverResponse
http.Request.write(self, message['content'])
File "/opt/anaconda2/lib/python2.7/site-packages/twisted/web/http.py", line 951, in write
self.transport.writeSequence(l)
exceptions.AttributeError: 'NoneType' object has no attribute 'writeSequence'
関連するApache構成は次のとおりです。
RewriteEngine On
DocumentRoot /var/www/html/django-ui
ProxyPass /static/ !
Alias /static/ /var/www/html/django-ui/cyberSA/static/
<Location "/">
ProxyPass "ws://localhost:8000/"
</Location>
http_protocol ファイルで問題を特定しようとしましたが、プロトコル オブジェクトに関連しているようです。ここで何が欠けていますか?