AI & Python #2: Two Tools Every Python Programmer Needs To Use
And a ChatGPT prompt that helped me use them like a ninja.
There are two tools I wish every Python programmer would learn once they mastered the basics: virtual environments and the terminal.
Why? Because as we learn Python by automating tasks and solving projects, it's important that each project is managed within its own virtual environment.
A virtual environment is a tool that helps keep dependencies required by different projects separate by creating isolated spaces for them. This is useful when we have projects that require different versions of the same library, preventing conflicts between them. Every time we start a new project we should set up a new virtual environment with all dependencies for the project.
The thing is, when you follow a coding tutorial, usually this step is omitted because it’s assumed you know how to create a virtual environment. Sadly, most beginners don’t know this fundamental concept, and when they hear they need to use the terminal for this, they get scared. That’s why today we’ll see how to use these two tools.
This article will have three parts. First, we’ll see some basic terminal commands. Then we’ll use some of these commands in the second part to create a virtual environment and, in the third part, I’ll show you the ChatGPT prompts that helped me use these tools like a ninja.