-
Notifications
You must be signed in to change notification settings - Fork 68
Error: no such option: --default #2101
Comments
@enigmadevs can you check if you have |
No, ptvsd is not in this path. |
I have the same problem. I found out that the command would work work fine in python 3.8 environment. The problem is that my project is not compatible with python 3.8 and therefore i have to use python 2.7. |
@int19h thanks for your feedback. Now i'm getting another error
Do you have a idea how i can get this running? |
Ohh, you're hitting #1574! Unfortunately, it's a bug in Flask (or rather Click) that we can't do much about. Flask already made a workaround for it, but they haven't shipped a stable release (1.1.2) with that yet. If you can downgrade Flask to 1.0.3, that's one possible workaround. |
@int19h thanks for your advice! Indeed downgrading Flask to 1.0.3 solved the problem. I'm able to debug even with the non-preview debugger for python now (in my case python debugger has currently version 2020.3.69010). |
Environment data
"python.jediEnabled"
set to; more info How to update the language server to the latest stable version vscode-python#3977): XXXpython.languageServer
setting: XXXExpected behaviour
It should start to debug my project
Actual behaviour
I receive this error:
C:\Users\s3rgy0\envs\venv\Scripts\python.exe c:\Users\s3rgy0.vscode\extensions\ms-python.python-2020.2.64397\pythonFiles\ptvsd_launcher.py --default --client --host localhost --port 51765 -m flask run --no-debugger --no-reload --host=192.168.0.163 --port=3002
Usage: python -m flask [OPTIONS] COMMAND [ARGS]...
Try "python -m flask --help" for help.
Error: no such option: --default
Steps to reproduce:
Logs
Output for
Python
in theOutput
panel (View
→Output
, change the drop-down the upper-right of theOutput
panel toPython
)Output from
Console
under theDeveloper Tools
panel (toggle Developer Tools on underHelp
; turn on source maps to make any tracebacks be useful by runningEnable source map support for extension debugging
)I don't know if this is a bug but i couldn't find any info about this error anywhere. I could debug flask with vscode in os x without problems, but in windows i receive this error. I repeat the tutorial multiple times but the result is always the same. The tutorial is written by python 3 but i changed the "env" to "virtualenv", i don't know if i should make any other change.
i think the problem is with python extension but i didn't be able to find any config file to modify this command:
C:\Users\s3rgy0\envs\venv\Scripts\python.exe c:\Users\s3rgy0.vscode\extensions\ms-python.python-2020.2.64397\pythonFiles\ptvsd_launcher.py --default --client --host localhost --port 51765 -m flask run --no-debugger --no-reload --host=192.168.0.163 --port=3002
If i could remove this options: "--default --client --host localhost --port 51765" it should work, but i don't know how.
Please help.
Thanks.
The text was updated successfully, but these errors were encountered: