Skip to content

Commit 47a5d45

Browse files
authored
feat: use root dir to start python and celery (langgenius#5515)
1 parent dcec9d7 commit 47a5d45

File tree

1 file changed

+20
-21
lines changed

1 file changed

+20
-21
lines changed
+20-21
Original file line numberDiff line numberDiff line change
@@ -1,44 +1,43 @@
11
{
2-
// Use IntelliSense to learn about possible attributes.
3-
// Hover to view descriptions of existing attributes.
4-
// For more information, visit: https://go.microsoft.com/fwlink/?linkid=830387
52
"version": "0.2.0",
63
"configurations": [
74
{
8-
"name": "Python: Celery",
5+
"name": "Python: Flask",
96
"type": "debugpy",
107
"request": "launch",
11-
"module": "celery",
8+
"python": "${workspaceFolder}/api/.venv/bin/python",
9+
"cwd": "${workspaceFolder}/api",
10+
"envFile": ".env",
11+
"module": "flask",
1212
"justMyCode": true,
13-
"args": ["-A", "app.celery", "worker", "-P", "gevent", "-c", "1", "--loglevel", "info", "-Q", "dataset,generation,mail"],
14-
"envFile": "${workspaceFolder}/.env",
13+
"jinja": true,
1514
"env": {
1615
"FLASK_APP": "app.py",
1716
"FLASK_DEBUG": "1",
1817
"GEVENT_SUPPORT": "True"
1918
},
20-
"console": "integratedTerminal",
21-
"python": "${command:python.interpreterPath}"
19+
"args": [
20+
"run",
21+
"--host=0.0.0.0",
22+
"--port=5001",
23+
]
2224
},
2325
{
24-
"name": "Python: Flask",
26+
"name": "Python: Celery",
2527
"type": "debugpy",
2628
"request": "launch",
27-
"module": "flask",
29+
"python": "${workspaceFolder}/api/.venv/bin/python",
30+
"cwd": "${workspaceFolder}/api",
31+
"module": "celery",
32+
"justMyCode": true,
33+
"envFile": ".env",
34+
"console": "integratedTerminal",
2835
"env": {
2936
"FLASK_APP": "app.py",
3037
"FLASK_DEBUG": "1",
3138
"GEVENT_SUPPORT": "True"
3239
},
33-
"args": [
34-
"run",
35-
"--host=0.0.0.0",
36-
"--port=5001",
37-
"--debug"
38-
],
39-
"jinja": true,
40-
"justMyCode": true,
41-
"python": "${command:python.interpreterPath}"
42-
}
40+
"args": ["-A", "app.celery", "worker", "-P", "gevent", "-c", "1", "--loglevel", "info", "-Q", "dataset,generation,mail"],
41+
},
4342
]
4443
}

0 commit comments

Comments
 (0)