PyCharm current working directory

前端 未结 8 1409

Recently, I\'m unable to use relative paths in my code while using PyCharm. For instance, a simple open(\'test.txt\', \'r\') will not work - whereupon I am sure

8条回答
  •  -上瘾入骨i
    2020-11-28 08:28

    Sometimes it is different. I solved my problem by clicking "Run" at the Pycharm's toolbar and then "Edit Configurations..." and I change my Interpreter to another actual one. Just changing it in the settings does not help, but this opperation already does ;)

提交回复
热议问题