HOW TO use Pycharm to debug python script?

后端 未结 4 1766
不思量自难忘°
不思量自难忘° 2020-12-15 18:14

I\'m trying to use pycharm. I can write code and run it. However, I do not know how to to debug the code. When I click the debug button, I get something similar to the belo

4条回答
  •  感动是毒
    2020-12-15 18:57

    I had similar problem in the past when trying to debug with pycharm. The solution was to start the debuging anywhere (first break point) in the file containing the following code:

    def main():
        
    
    if __name__ == "__main__":
        main()
    

提交回复
热议问题