I'm following this tutorial - Dev Ed <3 Usually I complete his tutorial with no major problem.. but this one I'm stuck at 4:05 minute mark.
I install all the packages as he does, but when I try to scrape like this :
(venv) C:\Users\Mario\PycharmProjects\Bitanga>python scraper.py
I get this
C:\\Users\\Mario\\AppData\\Local\\Programs\\Python\\Python38-32\\python.exe: can't open file 'scraper.py': [Errno 2] No such file or directory
Why? I have bs4 installed and requests.
Your computer can't find scraper.py
. Check your "C:\\Users\\Mario\\PycharmProjects\\Bitanga", is there scraper.py
there?
The error indicates that the file doesn't exist in that directory. Make sure you're in the correct directory where your file is located (eg C:\\\\Users\\Me\\Desktop
) using the cd
command in terminal. You can list the files in the current directory with the ls
or dir
command in terminal.
Could also be that your file is named something else. Maybe you have a typo in the file name? Have you saved the file before running it?
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.