python - Flask AttributeError:“str”对象没有属性“wrap_socket”
问题描述
当我运行我的烧瓶微服务时,我得到如下所示的错误:“AttributeError:'str'对象没有属性'wrap_socket'”
当我安装 pyopenssl 时出现此错误
app = Flask(__name__)
@app.route('/', methods=['POST', 'GET'])
def main_page():
return render_template('sign.html')
if __name__ == '__main__':
app.run(port=5000 ,host="localhost", ssl_context='', debug=True)
解决方案
推荐阅读
- javascript - 从导出的函数中反应类组件中的调用函数
- ansible - Ansible playbook 未在 GitHub Actions 中运行
- jquery - 仅使用 jQuery 从链接中删除元素
- sql - 从 SQL 填充用户表单上的复选框时,VBA 中的运行时错误 91
- python - 在 python 中跟踪散点图和视频
- cmake - 当我在字符串中有空格时,有没有办法避免 cmake 添加“\”?
- r - 推导R中所有可能矩阵的蛮力
- amazon-web-services - 在 AWS 服务中分离项目的最佳方式是什么?
- mysql - 为什么这些sql查询需要这么长时间才能执行
- c# - 网格视图中的行编辑 C#