-
-
Notifications
You must be signed in to change notification settings - Fork 48
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Flask application process closes after a few seconds #85
Comments
Could be related to multiprocessing, see mfussenegger/nvim-dap#858 (comment) You could set |
@mfussenegger thanks for your quick response! So, I did as you suggested and got the following log files: I'm not sure what those logs mean 🤔 |
I tried a more minimal version and it works for me: Setup: python -m venv venv
venv/bin/python -m pip install Flask Create {
"version": "0.2.0",
"configurations": [
{
"type": "python",
"request": "launch",
"name": "Flask",
"module": "flask",
"args": ["--app", "foo", "run"],
"console": "integratedTerminal"
}
]
} Create from flask import Flask
app = Flask(__name__)
@app.route("/")
def hello():
return "<p>Hello World</p>" Maybe something odd going on with your use of poetry. I don't use it myself so I can't help you with that. |
@mfussenegger I was able to at least launch the debugger by running in a shell that has the venv activated (using
Any ideas of what can I do? I tried opening the issue on Poetry's repo, but they aren't very helpful. |
Hi everyone.
I'm trying to setup the debugger in my Flask application (using Poetry) but when I launch the configuration for some reason the Flask application closes after a few seconds.
Everything is working (besides that). The application is launching properly, but after it finishes bootstrapping the process is closed after a few seconds.
About my env:
When I run the application, this is what I get in the intergrated terminal:
(the
Process exited
message takes a few seconds to appear)Also, I've already tried to remove the
--no-debug
flag, the result is the same. And, of course, if I run thepoetry run flask run
outside of the debugger it works as expected (the server is launched and stays live)The text was updated successfully, but these errors were encountered: