When working on a python project its always advisable to create for it a virtual environment.
Steps for doing that include :
Navigate to the project's directory then
Run python -venv dev
-note dev is just the name of the virtual environment ,your free to name it however you prefer.
3.Activate the virtual environment using this command :
-Note if you are using windows run dev\Scripts\activate
- create a requirements.txt file using the command : ** pip freeze > requirements.txt**
this file will contain all packages installed for thespecified project.
Install any packages required using pip install
Repeat command in step 4, to update the requirements.txt.