0

在我安装“频道”之前一切正常。安装频道后,我在 settings.py 的 INSTALLED_APPS 中添加了“频道”,然后当我执行 $ python3 manage.py runserver 时出现以下错误:

pi@raspberrypi:~/Desktop/project $ python3 manage.py runserver
Unhandled exception in thread started by <function check_errors.<locals>.wrapper at 0x75966300>

Traceback (most recent call last):
  File "/usr/local/lib/python3.4/dist-packages/django/utils/autoreload.py", line 226, in wrapper
fn(*args, **kwargs)
  File "/usr/local/lib/python3.4/dist-packages/django/core/management/commands/runserver.py", line 113, in inner_run
autoreload.raise_last_exception()
  File "/usr/local/lib/python3.4/dist-packages/django/utils/autoreload.py", line 249, in raise_last_exception
six.reraise(*_exception)
  File "/usr/local/lib/python3.4/dist-packages/django/utils/six.py", line 685, in reraise
raise value.with_traceback(tb)
  File "/usr/local/lib/python3.4/dist-packages/django/utils/autoreload.py", line 226, in wrapper
fn(*args, **kwargs)
  File "/usr/local/lib/python3.4/dist-packages/django/__init__.py", line 27, in setup
apps.populate(settings.INSTALLED_APPS)
  File "/usr/local/lib/python3.4/dist-packages/django/apps/registry.py", line 115, in populate
app_config.ready()
  File "/home/pi/channels/channels/apps.py", line 22, in ready
monkeypatch_django()
  File "/home/pi/channels/channels/hacks.py", line 10, in monkeypatch_django
from .management.commands.runserver import Command as RunserverCommand
  File "/home/pi/channels/channels/management/commands/runserver.py", line 5, in <module>
from daphne.server import Server
  File "/usr/local/lib/python3.4/dist-packages/daphne/server.py", line 4, in <module>
from twisted.internet import reactor, defer
  File "/home/pi/twisted/src/twisted/internet/reactor.py", line 38, in <module>
from twisted.internet import default
  File "/home/pi/twisted/src/twisted/internet/default.py", line 56, in <module>
install = _getInstallFunction(platform)
  File "/home/pi/twisted/src/twisted/internet/default.py", line 44, in _getInstallFunction
from twisted.internet.epollreactor import install
  File "/home/pi/twisted/src/twisted/internet/epollreactor.py", line 24, in <module>
from twisted.internet import posixbase
  File "/home/pi/twisted/src/twisted/internet/posixbase.py", line 18, in <module>
from twisted.internet import error, udp, tcp
  File "/home/pi/twisted/src/twisted/internet/tcp.py", line 28, in <module>
from twisted.internet._newtls import (
  File "/home/pi/twisted/src/twisted/internet/_newtls.py", line 21, in <module>
from twisted.protocols.tls import TLSMemoryBIOFactory, TLSMemoryBIOProtocol
  File "/home/pi/twisted/src/twisted/protocols/tls.py", line 63, in <module>
from twisted.internet._sslverify import _setAcceptableProtocols
  File "/home/pi/twisted/src/twisted/internet/_sslverify.py", line 1870, in <module>
"ECDH+AESGCM:ECDH+CHACHA20:DH+AESGCM:DH+CHACHA20:ECDH+AES256:DH+AES256:"
  File "/home/pi/twisted/src/twisted/internet/_sslverify.py", line 1850, in fromOpenSSLCipherString
SSL.SSLv23_METHOD, SSL.OP_NO_SSLv2 | SSL.OP_NO_SSLv3)
  File "/home/pi/twisted/src/twisted/internet/_sslverify.py", line 1802, in _expandCipherString
ctx.set_cipher_list(cipherString.encode('ascii'))
TypeError: must be str, not bytes

我不知道发生了什么,我非常感谢所有帮助。我安装了所有的包

$ sudo pip3 install 

我使用的系统是 RPi 3 上的 Raspbian。我在安装频道时收到很多警告,这与此错误有关吗?我真的需要一些帮助谢谢!

4

0 回答 0