I had been using PyCharm for a very long time whenever I am developing in Python.
It's one of the best IDEs for Python out there that I had encountered.
What blew me away for Visual Studio the most is their debugger & their IntelliSense.
This made me set a high bar for selecting an IDE for any new programming language.
It must have an excellent debugger and great IntelliSense.
It gives you a great list of shortcuts that allows you to improve your productivity in PyCharm.
I really like the
reformat code button which reformats your code to the coding style you had selected.
As mentioned, I choose PyCharm as my IDE is because the debugger works like what I had used in the past for visual studio.
Here are the steps to start debugging in Pycharm:
Add a red colour breakpoint by left-clicking your mouse in the line on where you would like the debugger to stop at.
Now click on the "debugger" button that which is just beside the "run" button for PyCharm to execute in the debug mode.
If you are running the debug mode for the first time. It might prompt you to install something for the debugger to make it run faster.
Now you have a bunch of arrows in the bottom of Pycharm.
Which is called Stepping.
This allows you to step through the execution of your program.
From the line by line (Step Into) execution to jumping directly to the next breakpoint (Step Out).
You can choose to change a different testing framework, which the default test runner is
You do it by going to
Python Integrated Tools ->
Default test runner.
Once your there, a prompt will ask you to fix the problem by clicking
fix to install the testing framework if you had not done so previously.
Another favourite of mine for PyCharm is the
autorun test toggle button in the red circle.
This allows you to set time delays to automatically run your test cases, after writing a piece of code which is quite useful for TDD.
I hope the tips are useful for making yourself more productive in using PyCharm.
Besides that regarding on testing portion for PyCharm. You can look at a video called Productive pytest with PyCharm that is created by both Jetbrians and Brian Okken.
Brian is the author of the book called Python Testing with pytest.
I pick up a few neat tricks in Pycharm when I'm selecting the default test runner as Pytest.
Especially the part in adding the
verbose option when running test cases for it.
If you like this article sign up for my Adventurer's Newsletter for a weekly update in the area of Python, Startup and Web Development.
You can also follow me to get the latest update of my article on Dev
The original post was on 3 Tips to be Effective In Pycharm - Reading Time: 3 Mins and cover image by Photo by Web Donut on Unsplash