I'm running a flask rest api using vscode as the IDE. I could setup the VSCode launcher in order to debug the application.
launch.json
{
"name": "Python: Flask",
"type": "python",
"request": "launch",
"module": "flask",
"env": {
"FLASK_APP": "wsgi.py",
"FLASK_ENV": "development",
"FLASK_DEBUG": "1"
},
"args": [
"run",
"--host",
"0.0.0.0",
"--port",
"5000",
],
"jinja": false,
"justMyCode": true
},
I need to use web sockets, so I've installed flask_socketio and eventlet extensions. To make the app working again I've replaced
if __name__ == '__main__':
app.run(host="0.0.0.0", port=5000)
by
if __name__ == '__main__':
socketio.run(app, host="0.0.0.0", port=5000, debug=True, use_reloader=True, log_output=True)
After that, the VS Debugger stopped working.
Do any of you know if it is possible to configure VSCode to continue debugging this app?
Thanks in advance