Full Web Apps with FastAPI Transcripts
Chapter: Setup and following along
Lecture: Do you have Python?

Login or purchase this course to watch this video and the rest of the course contents.
0:00 Before we start writing code and just jump right into our editor, let's make sure that you have your machine set up and you can follow along,
0:08 and you can build these applications with the course. It's really important that you follow along.
0:14 So when we do stuff in the course at the end of a chapter, stop and go back and add that to either the same application that you're building along
0:21 with me or create a parallel but very similar application and add the functionality over there So in this super short chapter,
0:29 what we're going to do is just go through and make sure that your machine has all the requirements and tools that you need.
0:35 The first question is, do you have Python? And importantly, is it the right version? FastAPI has a minimum requirement of Python 3.6,
0:44 and we're also using features like f-strings in our code that require Python 3.6 or later. So you need 3.6 we're actually gonna be using,
0:53 a higher version. But make sure you have at least Python 3.6. You wanna know, do I have Python? It's a little bit complicated to tell,
1:00 but here's a couple things we can do. If you're on Mac or Linux, Yu can go and type Python3 -V and you'll get some kind of answer.
1:10 Either Python 3 doesn't exist, in which case you need to go get Python or make sure it's in your path. Or it might be higher version lower version,
1:18 whatever. You need to make sure that this runs and that you get 3.6 or above, we're gonna be using 3.9.1 Actually,
1:24 during this course. On Windows, it's a little bit less obvious. There's a few things that make this challenging if you're not totally sure.
1:32 So on Windows, what you type usually is Python, not Python3, even though you want Python 3. So you say Python -V.
1:41 And if you get an output like this Python 3.9, 3.9.1 or whatever as longs that's above 3.6, you're
1:47 good to go, but here's where it gets tricky if your path is set up to find, say Python 2. But you actually have Python 3 in your system
1:56 it's just later in the path definition. You're going to need to adjust your path or be a little more explicit how you
2:01 reference that executable. And here is the super tricky part. Python on Windows 10 is not included.
2:08 But there is this Shim application whose job is to take you to the windows store and help you get Python. If you don't have it yet,
2:17 it will respond to Python -V but it will respond by having no output.
2:23 It won't tell you that Python is not actually installed that you need to go to the store and get it. It will just do nothing.
2:29 So if you type Python -V and nothing happens, that means you don't actually have Python. You just have the shim that if you took away the V,
2:38 would open the Windows store for you to get it and so on. So just make sure you get an actual output when you say Python -V
2:46 or, you know, follow the instructions coming up on how to get it. Speaking of getting Python, if you need it,
2:52 go visit realPython.com/installing-Python/. They've got a big range of options for all the different operating systems,
3:00 the trade offs, how to install it for your operating system. And they're keeping this up to date.
3:04 So just drop over there, get it installed in your machine and come back to the course, ready to roll.

Talk Python's Mastodon Michael Kennedy's Mastodon