功能不受此问题的影响,但是从中看到控制台垃圾邮件非常令人讨厌。在许多堆栈溢出问题中都曾问过这种错误,但似乎没有一个与这种错误的变化完全匹配。
这些是我的设置的组件,我相信可能会影响此问题:
import ssl
from flask import Flask, jsonify
from flask_restful import Api, Resource, reqparse, request
from flask_cors import CORS
...
app = Flask(__name__)
cors = CORS(app, resources={r"*": {"origins": "*"}})
api = Api(app, default_mediatype='application/json')
api.add_resource(SystemProperties, '/assets/system/properties/<property>')
...
context = ('/etc/ssl/server_crt.pem', '/etc/ssl/server_key.pem')
app.run(host='0.0.0.0', threaded=True, port=18080, debug=False, ssl_context=context)
我尝试更新所有软件包,包括openssl,pyopenssl。我已经安装了ndg-httpsclient pyasn1 urllib3。
Error on request:
Traceback (most recent call last):
File "/usr/local/lib/python3.5/dist-packages/werkzeug/serving.py", line 303, in run_wsgi
execute(self.server.app)
File "/usr/local/lib/python3.5/dist-packages/werkzeug/serving.py", line 296, in execute
write(b"")
File "/usr/local/lib/python3.5/dist-packages/werkzeug/serving.py", line 275, in write
self.wfile.write(data)
File "/usr/lib/python3.5/socket.py", line 594, in write
return self._sock.send(b)
File "/usr/lib/python3.5/ssl.py", line 869, in send
return self._sslobj.write(data)
File "/usr/lib/python3.5/ssl.py", line 594, in write
return self._sslobj.write(data)
ssl.SSLEOFError: EOF occurred in violation of protocol (_ssl.c:1949)