使用PyCharm终端参数进行调试

Lio*_*cer 37 python pycharm

我一直在使用PyCharm,所以我不是专家.

我通常如何运行我的程序是这样的终端:

program.py -t input1 -t1 input2

我想知道如何调试这个?

对于我写的其他程序,我没有任何参数,所以调试只是设置断点并按下调试.

And*_*vov 63

菜单:Run- > Edit configurations- > "+" (add new config)- > Python.

脚本名称: program.py

脚本参数: tox


Jeb*_*avi 29

只是答案的图像明智表示

第一步:点击Run菜单点击Edit configuration

在此处输入图片说明

  1. 选择+在右上角选择python

在此处输入图片说明

  1. 提供name, absolutepath of the script/ select the script by clicking three dots(green marker,script paramterspython interpreter

在此处输入图片说明