How to step into another .py file while debugging in PyCharm
Answered
In my current project I have a script that contains the line:
exec(open(pathname/script.py).read())
Which is supposed to execute a file in another folder (but still contained within the Pycharm project root directory).
When I debug this script and get to the line above, clicking 'Step into' or 'Step into my code' does not take me into script.py. I guess this is not the right syntax to use in order to step into another script? What syntax should I use? Thanks
Please sign in to leave a comment.
Hi awa5114! Unfortunately, such construction isn't supported with "Step Into" action. And at the moment it isn't possible to step into exec() statements. Please, create an issue in our issue tracker: https://youtrack.jetbrains.com/issues/pycharm
Hello Elizabeth! : )
Do you have any news on this feature (the capability to enter a .py file when executing "Step into")?
Thanks.
Hi Andrelfnovaes! Not yet, unfortunately. Feel free to vote for the issue:
https://youtrack.jetbrains.com/issue/PY-35912