Learn more about Thonny in our dedicated course: Thonny: The Beginner-Friendly Python Editor
Overview & Use Cases
00:00 In this section, we’re going to talk about Thonny, which is a very beginner-friendly Python editor. We have a tutorial on how to use Thonny on Real Python, so I’ll link that down there in the course notes for getting installation instructions and help on that. Go there and check it out after the course.
After you’ve downloaded and installed it, this is how it’s going to look when you open it up. You don’t have
print("Hello World!") in there yet, but you’re going to see these two windows probably. First of all, our editor—up here—and down here, we have a shell.
00:40 We have a Python console and an editor by default. There’s more, and I’m going to show you this in a moment. And then we also have a slim, but very useful, command palette up here. Like saving, opening a new file, running something, debugging, and already some features for debugging.
01:08 You can do that with Command + Shift + Plus. You see, Increase font size, Command + Shift + Plus. Or make it a little smaller. You can see here that it does syntax highlighting by default, so that’s already a great plus. And it also gives us hints when there’s some syntax errors. It’s marked here in green, we can notice that something’s going wrong.
And we can run this code right from in here, so I can say, “I built this, now I want to run it.” The first time I run it, it tells me—okay, currently it’s just a scratch file. We didn’t give it any name yet, so I need to save it somewhere. We’re just going to say
test.py and save it. And here we see, we can run our script and we can see the output down here in our shell.
And here’s some explanations that are just great when you’re getting started. So, we’re getting a
SyntaxError: EOL (end of line)
while scanning string literal, and then we have a description of what does this mean.
You haven’t properly closed the string on line 1.
If you want a multi-line string—so, there’s lots of interesting and helpful information right in here that helps you as a beginner to be—like, if you don’t exactly know yet what is a
SyntaxError, you can read up on it here and quickly figure out what’s going wrong.
And then there’s also more links for directly, like, performing a web search. It’s giving you hints on what you could type, so we have this, for example, which just picks out the
SyntaxError and that’s Python up in front.
03:12 You can literally copy this and go to Google and figure out what you can find there. So this Assistant is a helpful tool that can just help you to improve your code and learn while you’re coding.
03:23 So it’s kind of like an integrated coding/learning environment, Thonny. Okay. And that already nicely describes what is the main point of using Thonny, is if you’re getting started and you want to learn Python, then this is just a great IDE to get started with because there’s so much support, it’s very simple, and yet at the same time, it’s very powerful.
Become a Member to join the conversation.